Thursday, February 23, 2017

Gamemaker Day 10

Today I learned how to make the game over whenever the player touch the enemy or the enemy exits the room, then the center of the game will show "Game over" and "press R to restart". I learned a few function today, like "draw_set_halign(fa_center)" and "draw_set_valign(fa_middle)". halign(fa_center) meaning that the text will appear on the horizontal center of the point(x,y). valign(fa_middle) meaning that the text will appear on the vertical center of the point(x,y).
Also I learned a trick that can make the point(x,y) local at the center of the game. by typing room_with/2 and room_height/2. which is half width of the room and half height of the room.
Today I made my game text to new fonts, so it make the game less bored. I made the game over when player touch the enemy or the enemy exits to room.then appear the "gameover" text.


The next Day I'm going to watch Lives, so that player won't lose right away. 

No comments:

Post a Comment