![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | Leafousio |
extends Node2D
var char_pos = Vector2()
var Col_point = Vector2()
func _process(_delta):
char_pos = get_node(“KinematicBody2D”).get(“char_pos”)
Col_point = get_node(“KinematicBody2D”).get(“Col_point”)
func _draw():
draw_line(char_pos, Col_point ,ColorN("Black"), 2.0 , true)
(Variables char_pos and Col_point return right Vector2 values)
I think you need to call update()
to use _draw()
.
Adam_S | 2020-03-18 16:14