diff options
| author | Juan Linietsky | 2015-06-29 00:29:49 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2015-06-29 00:29:49 -0300 |
| commit | 95047562d743b1c1fdc007432c8a0c145a455c5d (patch) | |
| tree | f563e5c900c4330fcc602b6e5a721bc63022b253 /scene/resources/mesh.cpp | |
| parent | 2b64f73b0459190d20b2f6de39275ee7979317c4 (diff) | |
| download | godot-95047562d743b1c1fdc007432c8a0c145a455c5d.tar.gz godot-95047562d743b1c1fdc007432c8a0c145a455c5d.tar.zst godot-95047562d743b1c1fdc007432c8a0c145a455c5d.zip | |
Diffstat (limited to 'scene/resources/mesh.cpp')
| -rw-r--r-- | scene/resources/mesh.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/scene/resources/mesh.cpp b/scene/resources/mesh.cpp index 039a4788d..8cb090441 100644 --- a/scene/resources/mesh.cpp +++ b/scene/resources/mesh.cpp @@ -99,7 +99,7 @@ bool Mesh::_set(const StringName& p_name, const Variant& p_value) { if (sl==-1) return false; int idx=sname.substr(8,sl-8).to_int()-1; - String what = sname.get_slice("/",1); + String what = sname.get_slicec('/',1); if (what=="material") surface_set_material(idx,p_value); else if (what=="name") @@ -117,8 +117,8 @@ bool Mesh::_set(const StringName& p_name, const Variant& p_value) { return false; - int idx=sname.get_slice("/",1).to_int(); - String what=sname.get_slice("/",2); + int idx=sname.get_slicec('/',1).to_int(); + String what=sname.get_slicec('/',2); if (idx==surfaces.size()) { @@ -180,7 +180,7 @@ bool Mesh::_get(const StringName& p_name,Variant &r_ret) const { if (sl==-1) return false; int idx=sname.substr(8,sl-8).to_int()-1; - String what = sname.get_slice("/",1); + String what = sname.get_slicec('/',1); if (what=="material") r_ret=surface_get_material(idx); else if (what=="name") @@ -195,7 +195,7 @@ bool Mesh::_get(const StringName& p_name,Variant &r_ret) const { return false; - int idx=sname.get_slice("/",1).to_int(); + int idx=sname.get_slicec('/',1).to_int(); ERR_FAIL_INDEX_V(idx,surfaces.size(),false); Dictionary d; |
