summaryrefslogtreecommitdiffhomepage
path: root/app/systems/start_game.rb
diff options
context:
space:
mode:
authorarngo <[email protected]>2021-12-26 22:30:44 -0500
committerarngo <[email protected]>2021-12-26 22:30:44 -0500
commit930802e49e33c87ef0fd2f102b9205a4098878d3 (patch)
tree56cbf22ebbb4b16ac037eb2f525ca15d5656b96f /app/systems/start_game.rb
parent70b2499a8753331b68fb7a61a8882c9ff0b017d8 (diff)
downloadSteelWings-930802e49e33c87ef0fd2f102b9205a4098878d3.tar.gz
SteelWings-930802e49e33c87ef0fd2f102b9205a4098878d3.zip
implement score ui
Diffstat (limited to 'app/systems/start_game.rb')
-rw-r--r--app/systems/start_game.rb28
1 files changed, 26 insertions, 2 deletions
diff --git a/app/systems/start_game.rb b/app/systems/start_game.rb
index 4d6289e..a0073bd 100644
--- a/app/systems/start_game.rb
+++ b/app/systems/start_game.rb
@@ -56,14 +56,38 @@ FF::Sys.new('StartGame', priority: 50 ) do
FF::Cmp::Hitcircle.new(r: 32),
)
-
+ score_label_shadow = FF::Cmp::Label.new
+ score_label_shadow.props.merge!({
+ x: 50,
+ y: 667,
+ text: '0',
+ size_enum: 8,
+ r: 100,
+ g: 100,
+ b: 100,
+ font: 'fonts/kenvector_future_thin.ttf',
+ })
+ score_label = FF::Cmp::Label.new
+ score_label.props.merge!({
+ x: 50,
+ y: 670,
+ text: '0',
+ size_enum: 8,
+ font: 'fonts/kenvector_future_thin.ttf',
+ })
+ score = FF::Cmp::SingletonScore[0]
+ score.score = 0
+ FF::Ent.new(
+ score_label,
+ score_label_shadow,
+ score,
+ )
FF::Stg.add(
FF::Scn::BoidRules,
FF::Scn::Camera,
FF::Scn::Cleanup,
)
-
FF::Scn::Debug.add(FF::Sys::DebugRenderVectorArrow)
@pause = false
#FF::Stg.remove FF::Scn::BoidRules