Browse Source

Merge pull request #1844 from Vikram1323/patch-1

Update gdscript_basics.rst
Nathan Lovato 6 years ago
parent
commit
0b1214e710
1 changed files with 2 additions and 2 deletions
  1. 2 2
      getting_started/scripting/gdscript/gdscript_basics.rst

+ 2 - 2
getting_started/scripting/gdscript/gdscript_basics.rst

@@ -488,8 +488,8 @@ Starting with Godot 2.1, indices may be negative like in Python, to count from t
     var b = arr[1] # This is 2.
     var b = arr[1] # This is 2.
     var c = arr[arr.size() - 1] # This is 3.
     var c = arr[arr.size() - 1] # This is 3.
     var d = arr[-1] # Same as the previous line, but shorter.
     var d = arr[-1] # Same as the previous line, but shorter.
-    arr[0] = "Hi!" # Replacing value 1 with "Hi".
-    arr.append(4) # Array is now ["Hi", 2, 3, 4].
+    arr[0] = "Hi!" # Replacing value 1 with "Hi!".
+    arr.append(4) # Array is now ["Hi!", 2, 3, 4].
 
 
 GDScript arrays are allocated linearly in memory for speed.
 GDScript arrays are allocated linearly in memory for speed.
 Large arrays (more than tens of thousands of elements) may however cause
 Large arrays (more than tens of thousands of elements) may however cause