Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- extends Node2D
- var myarr = [] # same as myarr = Array()
- func _ready():
- myarr = [-64,-32,-8,0,8,32,64]
- update()
- func _draw():
- var col = Color(1,0,0)
- for pos_x in myarr: # same as pos_x in [-64,-32,-8,0,8,32,64]
- draw_line( Vector2(), Vector2(pos_x, 32), col, 2)
- # Vector2() is same as Vector2(0,0)#
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement