main.gd 297 B

12345678910111213
  1. extends Control
  2. # load the SIMPLE library
  3. const SIMPLE = preload("res://bin/simple.gdns")
  4. var data = SIMPLE.new()
  5. func _on_Button_pressed():
  6. # data comes directly from the Go context
  7. $Label.text = "Data = " + data.get_data()
  8. data.HP += 1
  9. print("data.Blood is ", data.Blood)
  10. data.Blood += 1