How could I draw a charge metre above my player?

D

Den

Guest
I have the ability to charge a shot done i'm just not sure how to draw a sprite above the player that
indicates how charged the shot actually is. I'm pretty new to drawing things and haven't really done it
before which is why i'm trying to implement it in my current project.
Could someone explain how this could be done please? I wanna try to understand how to draw stuff like that
with code.
 
C

Ctl-F

Guest
So, for drawing stuff, you should read up on the game maker manual: https://docs.yoyogames.com/source/dadiospice/002_reference/drawing/index.html

Once you read up on that, how you display it is really up to you. You can draw a sprite with the draw_sprite function you could make a progress bar with draw_rectangle
The important thing to remember is that all of your drawing code has to go in the draw event
And if you use the draw event of an object with a game sprite attached you need to call draw_self for the object to show up in game.
Hope this helps
 
Top