question about a modified pit / trapdoor
question about a modified pit / trapdoor
Does anyone know how to make a pit that drops the party to another place than the level below that pit?
How would you make such a pit without using a telporter, but with for instance the custom target option that stairs use
is this possible, I cant seem to find the script line in the asset pack.. or are stair and pit behaviors hardcoded?
How would you make such a pit without using a telporter, but with for instance the custom target option that stairs use
is this possible, I cant seem to find the script line in the asset pack.. or are stair and pit behaviors hardcoded?
- zimberzimber
- Posts: 432
- Joined: Fri Feb 08, 2013 8:06 pm
Re: question about a modified pit / trapdoor
You can't give pits a custom destination. Your only way is using a teleporter, but only after the party fell to the level below.
You could hack around this by imitating a pit fall, and having an invisible teleporter teleport you to the new detestation as if the party fell from above.
Place a pit object, disable the pit component, have a 7 tile elevation drop, put an invisible teleporter at the bottom, set the teleporters destination to where you want the party to land + 1 elevation.
Something will not work though. Like using ropes, the "AAAH" sound (can still be added with a floor trigger), and the camera facing down while falling.
You could hack around this by imitating a pit fall, and having an invisible teleporter teleport you to the new detestation as if the party fell from above.
Place a pit object, disable the pit component, have a 7 tile elevation drop, put an invisible teleporter at the bottom, set the teleporters destination to where you want the party to land + 1 elevation.
Something will not work though. Like using ropes, the "AAAH" sound (can still be added with a floor trigger), and the camera facing down while falling.
Re: question about a modified pit / trapdoor
An alternative method [with its own pros&cons] is to place the teleporter above the ceiling on the level below the pit. In this way, the party falls (as usual), but can be made to land just about anywhere you wish.
What's nice about this, is that it uses a pit, but it doesn't have to affect the layout of the level below; the teleporter is above the ceiling... normally impossible to for the party to reach.

[updated] Example Project: https://www.dropbox.com/s/3ct6rol7tpjzb ... t.zip?dl=0
One of the cons [as mentioned above], is rope. Rope bypasses the effect entirely. This could be used as a feature of a puzzle, otherwise it would need to be handled if this was not intended.
***Doesn't yet handle use from attack panel, but I will update it soon, it's late; (it's 5AM here).
What's nice about this, is that it uses a pit, but it doesn't have to affect the layout of the level below; the teleporter is above the ceiling... normally impossible to for the party to reach.

[updated] Example Project: https://www.dropbox.com/s/3ct6rol7tpjzb ... t.zip?dl=0
One of the cons [as mentioned above], is rope. Rope bypasses the effect entirely. This could be used as a feature of a puzzle, otherwise it would need to be handled if this was not intended.
***Doesn't yet handle use from attack panel, but I will update it soon, it's late; (it's 5AM here).

Last edited by Isaac on Wed Jan 11, 2017 1:16 pm, edited 2 times in total.
- zimberzimber
- Posts: 432
- Joined: Fri Feb 08, 2013 8:06 pm
Re: question about a modified pit / trapdoor
You could still place a teleporter where the party would appear after using rope.
If the level below has a passage there or something, disable it when the party approaches it from the bottom level, and enable it when the party approaches the pit on the top level.
Automap will still show though.
If the level below has a passage there or something, disable it when the party approaches it from the bottom level, and enable it when the party approaches the pit on the top level.
Automap will still show though.
Re: question about a modified pit / trapdoor
brilliant, just what I needed. This helps alot.
thanks for the answers
thanks for the answers
Re: question about a modified pit / trapdoor
You can also just move the party wherever you want using a script without using a teleporter. Just use party:setPosition(x, y, party.facing, elevation, level) if that would help. I believe that the "fall" could be orchestrated anyway you like, especially if you disabled gravity (party.gravity:disable()) and used party:setWorldPosition(pos) and others - heck, you could even make them fall up with a floor trigger into a shaft above, then slam them sideways into a wall! I'm not sure of the FSP, but I'll bet it could work. Or you can trigger the pit, let the party fall for a fraction of a second via a delayed call to another included function, then move them wherever. Best Regards, -Lark
Re: question about a modified pit / trapdoor
One thing of note is that using the pit comes with automatically tilted camera and party [falling] sound; using an elevation drop does not. If they are falling, there needs to be a way to detect this. It can be done with hooks or triggered scripts, or a teleporter.Lark wrote:...I believe that the "fall" could be orchestrated anyway you like...
The big problem with floor_triggers and teleporters on the ground below, is that you see the ground approaching before the teleporter or script changes the party's position.
- zimberzimber
- Posts: 432
- Joined: Fri Feb 08, 2013 8:06 pm
Re: question about a modified pit / trapdoor
Another thing to note - If you started falling into a pit, you'll just keep falling, regardless of your position. (through floors and such) (At least if you use a teleporter after you fell)
Re: question about a modified pit / trapdoor
Do you have a clearer example?zimberzimber wrote:Another thing to note - If you started falling into a pit, you'll just keep falling, regardless of your position. (through floors and such) (At least if you use a teleporter after you fell)
(When I try falling into a pit with a teleporter in it, the engine prints a notice that it is "ignoring teleportation -- party falling to level below")
- zimberzimber
- Posts: 432
- Joined: Fri Feb 08, 2013 8:06 pm
Re: question about a modified pit / trapdoor
Before I started working on the asset pack, I recall I wanted to make a pit (that had water in it) and if the player fell into it, they would appear somewhere else. It did work, except the party just kept falling.Isaac wrote:Do you have a clearer example?zimberzimber wrote:Another thing to note - If you started falling into a pit, you'll just keep falling, regardless of your position. (through floors and such) (At least if you use a teleporter after you fell)
(When I try falling into a pit with a teleporter in it, the engine prints a notice that it is "ignoring teleportation -- party falling to level below")
Though, ti was a long time ago, maybe one of the patches prevents this from happening.