GameMaker: Studio

GameMaker: Studio

View Stats:
How to make a sprite have the ability to turn invisible for a limited time?
I am making a 2D platformer but I have no idea how to make the the sprite or main character have the ability to turn invisible to enemies and the player also can you make the sprite have an outline so the character knows where he is going.
Any help is welcome
Thanks
Last edited by mymumsaysimspecial; Apr 30, 2016 @ 7:14pm
< >
Showing 1-3 of 3 comments
Oyakiiv May 1, 2016 @ 12:06am 
to make it so that enemies can't 'detect' the player you can use a similar method as 'pausing' a game.

for this you just have to make a new variable 'global.invisible' and have it set to zero.

when you want the player to go invisible you can set this variable to 1. And you will can easily make it so this works for enemies by making it so they can only 'detect' the player when global.invisible = 0 by using a simple if statement.

if global.invisible = 0
{
// detection code goes here
}

as for changing the player characters image to a simple outline you have to use the sprite change code...that I dont remember atm...sorry, its in the help file though. If you would like me to look it up for you I can, but it is best to go through the file from time to time, you can really learn alot.
Thank you so much I can show you but my friend has the working version
Thanks for helping me out.
Oyakiiv May 1, 2016 @ 9:49am 
no problem
< >
Showing 1-3 of 3 comments
Per page: 1530 50

Date Posted: Apr 30, 2016 @ 6:54pm
Posts: 3