diff options
| author | Juan Linietsky | 2016-01-02 14:58:27 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2016-01-02 14:58:27 -0300 |
| commit | 32a6120a5cdd050d4874021aa80d3d104a4b637b (patch) | |
| tree | a95746e0c069aa0b9d7a0cda624e1c5585ce2adc /core/variant_op.cpp | |
| parent | cd3dfdaf18506c3ff2c41d8d94c7ec9fe12fbef5 (diff) | |
| download | godot-32a6120a5cdd050d4874021aa80d3d104a4b637b.tar.gz godot-32a6120a5cdd050d4874021aa80d3d104a4b637b.tar.zst godot-32a6120a5cdd050d4874021aa80d3d104a4b637b.zip | |
Diffstat (limited to 'core/variant_op.cpp')
| -rw-r--r-- | core/variant_op.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/variant_op.cpp b/core/variant_op.cpp index 9218406e0..204a00e1d 100644 --- a/core/variant_op.cpp +++ b/core/variant_op.cpp @@ -1003,7 +1003,7 @@ void Variant::set(const Variant& p_index, const Variant& p_value, bool *r_valid) return; } - *str = str->substr(0,idx-1)+chr+str->substr(idx+1,str->length()); + *str = str->substr(0,idx)+chr+str->substr(idx+1,str->length()); valid=true; return; @@ -1364,7 +1364,7 @@ void Variant::set(const Variant& p_index, const Variant& p_value, bool *r_valid) valid=true; v->b=float(p_value)/255.0; return; - } else if (*str=="a8" ) { + } else if (*str=="a8" ) {\ valid=true; v->a=float(p_value)/255.0; return; |
