Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Joined: Nov 2017
T
stranger
OP Offline
stranger
T
Joined: Nov 2017
hello to everyone, I've tried everywhere and tried in a variety of ways and after over one hundred hours of editors I still can not run a trap ... is there anyone who has already experienced and could share the information?

I would like to do something as simple as, for example, if the player walks on the pressure plate is struck by one or more arrows, or by activating a lever, the room is filled with poison gas, is there anybody so kind to help me? thanks a lot.

Joined: Oct 2017
Location: United Kingdom
journeyman
Offline
journeyman
Joined: Oct 2017
Location: United Kingdom
Place the pressure plate on the ground, open it for edit and in the side bar of the item properties, under "Scripts" open the "PUZZLE_PressurePlate" script and type a name for "EventOn" and "EventOff". For example "plateStepOn" and "plateStepOff".

Then you can make a script in the story editor with something like:

Code
IF
CharacterItemEvent(_Player,_PressurePlateGUID,"plateStepOn")
THEN
ShowNotification("Stepped on plate");
<whatever you want to do>


For a lever you can do something like the above with the "PUZZLE_Lever" script. Or do a script like (and place a PointTrigger where you want the poison cloud to appear)

Code
IF
CharacterUsedItem(_Player,_LeverGUID)
THEN
CreateSurface(_PointTriggerGUID,"SurfacePoisonCloud", 5.0, 10.0);
ShowNotification("Created poison cloud");

Joined: Oct 2017
Location: United Kingdom
journeyman
Offline
journeyman
Joined: Oct 2017
Location: United Kingdom
To shoot an arrow when you step on a plate:

- Place an item with the turret script, e.g. the "PUZ_Trap_Gargoyle_C" gargoyle.

- Prefix your pressure plate name with S_ so it becomes e.g. "S_PUZ_PressurePlate_Floor_A_000".

- Open the gargoyle for edit, go to the Scripts section, edit the "PUZZLE_Turret" script, set "TurretShootEvent" to "plateStepOn" and set the "TurretProjectileSkill" to e.g. "Projectile_StunningArrow".

- Set the "TargetItem" to the pressure plate

Then whenever you step on the plate it will shoot at the arrow at it. Don't think you set it to target a player though.

Joined: Oct 2017
Location: NH, USA
R
apprentice
Offline
apprentice
R
Joined: Oct 2017
Location: NH, USA
I Think you can target the player, provided you make your own itemscript; the pressure plate example script should have a variable referencing what triggered it, so from there you should be able to hodge-podge something together

Last edited by RestingLichFace; 09/11/17 07:38 PM.

Projects: Tomb of Horrors: Tomb of Horrors
Joined: Nov 2017
T
stranger
OP Offline
stranger
T
Joined: Nov 2017
-
It works perfectly simply coordinated the plate and the gargoyle, thank you very much, I did not need to use the story editor :) With S_ in front of the name everything has been fixed.


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5