I Wanna Community

Fangames => Game Design => Programming Questions => Topic started by: 128-Up on November 09, 2015, 09:40:00 PM

Title: Stopping blood splatter giving away fake/invisible blocks?
Post by: 128-Up on November 09, 2015, 09:40:00 PM
I'm using Lemon Engine on GM 8.0 and I want to know how to stop the blood from the Kid dying from landing on invisible blocks that haven't been revealed and going through fake blocks that haven't disappeared.
Title: Re: Stopping blood splatter giving away fake/invisible blocks?
Post by: Keygrin on November 09, 2015, 11:52:38 PM
If the blood is its own Object, make the invisible block Object an exception by having a collision event that executes code that doesn't include the blood stopping upon touching it.
Title: Re: Stopping blood splatter giving away fake/invisible blocks?
Post by: pieceofcheese87 on November 10, 2015, 06:21:34 AM
Just do this:
1. Go in the invisible block object, uncheck "solid" and remove the block parent
2. In the step event where it checks for a collision with player, add this under "visible = 1"
Code: [Select]
instance_create(x,y,block)
Title: Re: Stopping blood splatter giving away fake/invisible blocks?
Post by: 128-Up on November 18, 2015, 02:55:50 AM
Just do this:
1. Go in the invisible block object, uncheck "solid" and remove the block parent
2. In the step event where it checks for a collision with player, add this under "visible = 1"
Code: [Select]
instance_create(x,y,block)

I did this, but then I end up with the problem where you get stuck if you jump into an invisible block from below.
Title: Re: Stopping blood splatter giving away fake/invisible blocks?
Post by: L4Vo5 on March 12, 2016, 01:55:20 PM
You can always just delete all unrevealed invisible blocks if the player dies
On player death event:
with (insert invisible blocks name here) if visible = 0 instance_destroy()

if you have various invisible block objects, make a parent for them and just refer to the parent in the code above