AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   func_door_rotating help (https://forums.alliedmods.net/showthread.php?t=54888)

Bad_Bud 05-06-2007 16:25

func_door_rotating help
 
Is it possible to set a rotating door that opens on touch to NOT open on touch, or a rotating door that doesn't open on touch to open on touch?

I'm not looking to use force_use or any hooks, I'm just wondering if this can be done with entity keys, and if so, which ones.

stupok 05-06-2007 16:44

Re: func_door_rotating help
 
I haven't played with EntMod for ages, but if my memory serves me, you can just edit the keyvalue targetname to lock and unlock the door. Assign the door a targetname to lock it and remove the targetname to unlock it.

VEN 05-07-2007 04:24

Re: func_door_rotating help
 
You can look into hlsdk_const.inc
Quote:

// func_door, func_water, func_door_rotating, momementary_door
#define SF_DOOR_ROTATE_Y 0
#define SF_DOOR_START_OPEN 1
#define SF_DOOR_ROTATE_BACKWARDS 2
#define SF_DOOR_PASSABLE 8
#define SF_DOOR_ONEWAY 16
#define SF_DOOR_NO_AUTO_RETURN 32
#define SF_DOOR_ROTATE_Z 64
#define SF_DOOR_ROTATE_X 128
#define SF_DOOR_USE_ONLY 256 // Door must be opened by player's use button
#define SF_DOOR_NOMONSTERS 512 // Monster can't open
#define SF_DOOR_SILENT 0x80000000

Basically you need to set/unset SF_DOOR_USE_ONLY spawnflag before entity spawn.


All times are GMT -4. The time now is 06:41.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.