K
Kroan
Guest
Hi,
I have an enemy object that the player can focus on.
When an enemy is focused I want to draw a marker on it (a rotating circle to indicate that the enemy is focused)
I thought I could do that within the Draw event of the enemy object, however the animation speed of the circle is extremely fast.
The circle is animating fine in the sprite editor (I put it on a speed of 5 Frames per second.)
Here is what I tried:
Create of enemy
Draw event of enemy
I read that the image_speed is responsible for the multiplication of the speed so I set it to 1 for the focusedMarker but it doesn't make any difference.
Any help?
Thanks!
I have an enemy object that the player can focus on.
When an enemy is focused I want to draw a marker on it (a rotating circle to indicate that the enemy is focused)
I thought I could do that within the Draw event of the enemy object, however the animation speed of the circle is extremely fast.
The circle is animating fine in the sprite editor (I put it on a speed of 5 Frames per second.)
Here is what I tried:
Create of enemy
GML:
isFocused = false;
focusedMarker = sEnemyTargetMarker;
focusedMarker.image_speed = 1;
Code:
draw_self();
if(isFocused)
{
draw_sprite(focusedMarker,focusedMarker.image_index,x,y);
}
Any help?
Thanks!