HUD.tscn 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. [gd_scene load_steps=6 format=2]
  2. [ext_resource path="res://HUD.gd" type="Script" id=1]
  3. [ext_resource path="res://fonts/Xolonium-Regular.ttf" type="DynamicFontData" id=2]
  4. [sub_resource type="DynamicFont" id=1]
  5. size = 64
  6. use_mipmaps = false
  7. use_filter = false
  8. font_data = ExtResource( 2 )
  9. _sections_unfolded = [ "Font", "Settings" ]
  10. [sub_resource type="DynamicFont" id=2]
  11. size = 72
  12. use_mipmaps = false
  13. use_filter = false
  14. font_data = ExtResource( 2 )
  15. _sections_unfolded = [ "Font", "Settings" ]
  16. [sub_resource type="DynamicFont" id=3]
  17. size = 48
  18. use_mipmaps = false
  19. use_filter = false
  20. font_data = ExtResource( 2 )
  21. _sections_unfolded = [ "Font", "Settings" ]
  22. [node name="HUD" type="CanvasLayer"]
  23. layer = 1
  24. offset = Vector2( 0, 0 )
  25. rotation = 0.0
  26. scale = Vector2( 1, 1 )
  27. transform = Transform2D( 1, 0, 0, 1, 0, 0 )
  28. script = ExtResource( 1 )
  29. [node name="ScoreLabel" type="Label" parent="." index="0"]
  30. anchor_left = 0.5
  31. anchor_top = 0.0
  32. anchor_right = 0.5
  33. anchor_bottom = 0.0
  34. margin_left = -25.0
  35. margin_right = 25.0
  36. margin_bottom = 100.0
  37. rect_pivot_offset = Vector2( 0, 0 )
  38. rect_clip_content = false
  39. mouse_filter = 2
  40. mouse_default_cursor_shape = 0
  41. size_flags_horizontal = 1
  42. size_flags_vertical = 4
  43. custom_fonts/font = SubResource( 1 )
  44. text = "0"
  45. align = 1
  46. percent_visible = 1.0
  47. lines_skipped = 0
  48. max_lines_visible = -1
  49. _sections_unfolded = [ "Anchor", "Margin", "custom_fonts" ]
  50. [node name="MessageLabel" type="Label" parent="." index="1"]
  51. anchor_left = 0.5
  52. anchor_top = 0.5
  53. anchor_right = 0.5
  54. anchor_bottom = 0.5
  55. margin_left = -200.0
  56. margin_top = -150.0
  57. margin_right = 200.0
  58. margin_bottom = 50.0
  59. rect_pivot_offset = Vector2( 0, 0 )
  60. rect_clip_content = false
  61. mouse_filter = 2
  62. mouse_default_cursor_shape = 0
  63. size_flags_horizontal = 1
  64. size_flags_vertical = 4
  65. custom_fonts/font = SubResource( 2 )
  66. text = "Dodge the
  67. Creeps!"
  68. align = 1
  69. valign = 1
  70. percent_visible = 1.0
  71. lines_skipped = 0
  72. max_lines_visible = -1
  73. _sections_unfolded = [ "Anchor", "Margin", "custom_fonts" ]
  74. [node name="MessageTimer" type="Timer" parent="." index="2"]
  75. process_mode = 1
  76. wait_time = 2.0
  77. one_shot = true
  78. autostart = false
  79. [node name="StartButton" type="Button" parent="." index="3"]
  80. anchor_left = 0.5
  81. anchor_top = 1.0
  82. anchor_right = 0.5
  83. anchor_bottom = 1.0
  84. margin_left = -100.0
  85. margin_top = -200.0
  86. margin_right = 100.0
  87. margin_bottom = -100.0
  88. rect_pivot_offset = Vector2( 0, 0 )
  89. rect_clip_content = false
  90. focus_mode = 2
  91. mouse_filter = 0
  92. mouse_default_cursor_shape = 0
  93. size_flags_horizontal = 1
  94. size_flags_vertical = 1
  95. custom_fonts/font = SubResource( 3 )
  96. toggle_mode = false
  97. enabled_focus_mode = 2
  98. shortcut = null
  99. group = null
  100. text = "Start"
  101. flat = false
  102. align = 1
  103. _sections_unfolded = [ "Anchor", "Margin", "Visibility", "custom_fonts" ]
  104. [connection signal="timeout" from="MessageTimer" to="." method="_on_MessageTimer_timeout"]
  105. [connection signal="pressed" from="StartButton" to="." method="_on_StartButton_pressed"]