Page 1 of 1

Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 6:12 pm
by SpiderFighter
From the Scripting Reference:
PressurePlate:destroy()
Removes the entity from the level.
Simple enough, but when the plate is removed it creates a black void beneath, instead of the floor tile from that dungeon's wall set. Does anyone have any ideas as to how to get the floor to show after the plate is removed, please? (I'm hoping this hasn't been asked before...if it has, my apologies; I can't find it.)

Re: Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 6:15 pm
by HaunterV
that's wierd... unless you use hidden ones.

Re: Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 6:15 pm
by Grimwold
I've only ever used plate:destroy() on hidden pressure plates where that doesn't happen. If I want to 'disable' a visable pressure plate I always

Code: Select all

plate:setTriggeredByParty(false)
not sure if this fits your need though as it won't remove the plate from the floor.. just stop it being activated by the party (or monster/item depending).

Re: Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 6:18 pm
by SpiderFighter
HaunterV wrote:that's wierd... unless you use hidden ones.
Nope, this one is a vanilla "prison_pressure_plate."
Grimwold wrote:I've only ever used plate:destroy() on hidden pressure plates where that doesn't happen. If I want to 'disable' a visable pressure plate I always

Code: Select all

plate:setTriggeredByParty(false)
not sure if this fits your need though as it won't remove the plate from the floor.. just stop it being activated by the party (or monster/item depending).
I think that will work nicely, thanks! I'm just using it to prevent a script from crashing...leaving it on the floor is more realistic than having it suddenly disappear.

[EDIT: That worked brilliantly. No more crashing, and the puzzle now works as intended. Thanks again.]

Re: Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 8:46 pm
by HaunterV
whatabout putting down floor dirt so there is something to be rendered once the plate is removed?

Re: Quick question on removing pressure plates

Posted: Thu Nov 01, 2012 8:51 pm
by SpiderFighter
HaunterV wrote:whatabout putting down floor dirt so there is something to be rendered once the plate is removed?
Good thought. I don't need it anymore, but someone else down the road might find this thread useful. Lemme check it out, and I'll be back.

[EDIT: Couldn't get it to work at all with the dirt in the same space. Also, the dirt almsot completely covers the plate, no matter which order you place them in. While it doesn't work as a solution, it is a nifty trick for making plates that are almost entirely hidden!]