0

Opening a simple door on collision and or using a proximity detector

Hi Guys,

Before I start, I have to declare, scripting makes my eyes and brain go all fuzzy. I like procedural or drag and drop type scripting, not writing or digesting.

I have created a couple of gates (left and right handed) which are made using the correct hinge position in the model for rotating, so I don't need to use hinge offsets, all I need to have them do is rotate around one axis when either an avatar collides with them, or using a trigger box.

I inserted the simple door hinge script into each gate and set up the static position/rotations, then the opening position/rotation in the API of each script.

I placed a Trigger Box and inserted a Proximity script, however I could not discover how to set the trigger to fire the door scripts.

I tried setting the Gates to Dynamic and Keyframed physics. The former did allow me to bully my way through the gates but I am sure this was pure mass physics as opposed to a script handling any movement.

I have attached a couple of screenshots showing both gates and the trigger box complete with properties windows showing the script api's.

As I have many doors in my scenes, that I would prefer to automate, can someone explain (in non scripting language) how I set up the properties for this to work? I'd appreciate it.




 

6 comments

Please sign in to leave a comment.