Hundreds of features to explore
Games made in Construct
Your questions answered
Popular & trusted by schools and Universities world-wide
Construct 3 runs in the browser & works offline
Students do not need accounts with us
World class complete documentation
Official and community submitted guides
Learn and share with other game developers
Upload and play games from the Construct community
Game development stories & opinions
I am trying to create a game where the BALL (player) must find their way to a hole, but I can't figure out how to make the ball disappear when the roll over the hole.
Also, do I need an animation for this effect or can i just add the "fade" behavior to the ball.
Thank you for any help.
You can use the Fade behavior or you can simply use the "Set Visible" action.
Every object that can be displayed on the screen will have this action available to it.
You need to add an event like - 'ball on collision with hole' then actions like 'fade: start fade' :)
You can also specify an area of collision 'like bottom of the hole, also you can fade it or start an animation,'on collision. or both :)
post your capx file so someone can show you directly.
also: blend mode
Develop games in your browser. Powerful, performant & highly capable.
Thanks for the replies,
I forgot 1 important point, it's a topdown game. I did get the ball to disappear, but it does so rather quickly. I have messed around with fade out times but get the same result.
Again, thanks for the help.
Just set an event as..
Ball | On collision with hole ; Set opacity to lerp(Ball.Opacity,0,#number#*dt)
Here you go !
You may also use the same lerp numbers to scale the ball down as it fades, that way it simulates moving away from you as it enters the hole, disappearing in the darkness.
Is it possible to have a reverse lerp? As if the gold ball (player) falls down the hole the hole will spit it back out, say after 1 sec?
If it's "top-down", you also can change the size or the ball, when it's "in the hole". So it looks like the ball will "fall down".