From 32f4a501b1153f83e1871e6d5e47686bc4fce667 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Filip=20B=C3=A1rtek?= Date: Sun, 2 Feb 2014 20:22:31 +0100 Subject: [PATCH] Counts and draws score for individual players --- studna.gmx/objects/obj_pl.object.gmx | 47 ++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/studna.gmx/objects/obj_pl.object.gmx b/studna.gmx/objects/obj_pl.object.gmx index b7883ac..a65b77f 100644 --- a/studna.gmx/objects/obj_pl.object.gmx +++ b/studna.gmx/objects/obj_pl.object.gmx @@ -36,6 +36,8 @@ gravity_size = gravity_size_pps / room_speed; maxvspeed_pps = 480; maxvspeed = maxvspeed_pps / room_speed; +pl_score = 0; + @@ -112,6 +114,7 @@ if (place_free(x, y + 1)) { 1 /// Warp up if too low if (y >= view_yview[VIEW_MAIN] + view_hview[VIEW_MAIN] - 64) { + pl_score++; y = view_yview[VIEW_MAIN]; } @@ -174,6 +177,50 @@ gravity = 0; + + + 1 + 500 + 0 + 0 + 0 + 0 + 2 + + draw_self(); + self + 0 + 0 + + + 1 + 514 + 0 + -1 + 0 + -1 + 1 + action_draw_text + + self + 0 + 0 + + + 2 + "" + string(pl_score) + + + 0 + x + + + 0 + y + + + + 0 0