Frictional Games Forum (read-only)

Full Version: [SOLVED] Using a Single Crowbar on Multiple Doors
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5
You can try setting a string variable to what door is being used.

SetLocalVarString("CurrentDoor", asEntity);

CreateParticleSystemAtEntity("", "ps_hit_wood.ps", GetLocalVarString("CurrentDoor"), false);
Where would the SetLocalVarString be placed?
Right when you use the crowbar on a door. There's no need to check which entity it's being used at.
No, that's not gonna help, since she wants it to happen at an area, which hasn't been used before. Therefore asEntity would not be a possibility.

I know my solution works. I also know why it didn't work.

It shouldn't be +asParent. It should be +asChild

I hadn't checked what was asParent and asChild in your script.


So everything must be like this:

Areas named like: "AreaEffect_AreaBreak_1"

Script looking like:
PHP Code:
CreateParticleSystemAtEntity("""ps_hit_wood.ps""AreaEffect_"+asChildfalse);
    
PlaySoundAtEntity("""break_wood_metal""AreaEffect_"+asChild0false); 
That did it!! +asChild has fixed it!! XD
Woop! We have done it! The issue has been fixed! Wubwubwubwubwub!

I hope you learned something!
A lot! Really! Thanks ever so much!!
Pages: 1 2 3 4 5