From 3c4947201d600718b3c2c33fc738d7d429182a92 Mon Sep 17 00:00:00 2001 From: przemek Date: Sun, 9 Oct 2011 15:05:16 +0200 Subject: [PATCH] entities definitions for data branch atheros/item_keys (item_key1, item_key2, trigger_keylock) --- scripts/entities.def | 52 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/scripts/entities.def b/scripts/entities.def index 7f4d5a47..4aa7a474 100644 --- a/scripts/entities.def +++ b/scripts/entities.def @@ -129,7 +129,7 @@ health: (default 0) if set to any non-zero value, the button must take damage (a NOSPLASH: if set, splash damage cannot activate the door, only direct damage can (requires health to be set) */ -/*QUAKED func_door (0 .5 .8) ? START_OPEN - DOOR_DONT_LINK - - TOGGLE - - NOSPLASH +/*QUAKED func_door (0 .5 .8) ? START_OPEN - DOOR_DONT_LINK GOLD_KEY SILVER_KEY TOGGLE - - NOSPLASH Normal sliding door entity. By default, the door will activate when player walks close to it or when damage is inflicted to it. If DOOR_DONT_LINK is not set, the door will be linked with all doors it touches. Note however that for linked doors to work properly, it is necessary that ALL linked doors have SOME volume of common area (that is, there must be a point that is part of ALL doors). -------- KEYS -------- @@ -149,6 +149,8 @@ noise2: sound when the door closes -------- SPAWNFLAGS -------- START_OPEN: causes the door to move to its destination when spawned, and operate in reverse. It is used to temporarily or permanently close off an area when triggered (not useful for touch or damage triggered doors). DOOR_DONT_LINK: the door won't link with another door it touches +GOLD_KEY: causes the door to open only if the activator holds a gold key. +SILVER_KEY: causes the door to open only if the activator holds a silver key. TOGGLE: causes the door to wait in both the start and end states for a trigger event. NOSPLASH: if set, splash damage cannot activate the door, only direct damage can (requires health to be set) */ @@ -573,6 +575,30 @@ FLOATING: the item will float in air, instead of aligning to the floor by fallin modeldisabled="models/items/g_invincible.md3" */ +/*QUAKED item_key1 (0 .5 .8) (-16 -16 -24) (16 16 32) FLOATING +SILVER key. +-----------KEYS------------ +colormod: color of the key (default: '.9 .9 .9'). +message: message to print when player picks up this key. +model: custom model to use. +noise: custom sound to play when player picks up the key. +-------- SPAWNFLAGS -------- +FLOATING: the item will float in air, instead of aligning to the floor by falling +---------NOTES---------- +*/ + +/*QUAKED item_key2 (0 .5 .8) (-16 -16 -24) (16 16 32) FLOATING +GOLDEN key. +-----------KEYS------------ +colormod: color of the key (default: '1 .9 0'). +message: message to print when player picks up this key. +model: custom model to use. +noise: custom sound to play when player picks up the key. +-------- SPAWNFLAGS -------- +FLOATING: the item will float in air, instead of aligning to the floor by falling +---------NOTES---------- +*/ + /*QUAKED item_minst_cells (.3 .3 1) (-30 -30 0) (30 30 32) FLOATING Minstagib ammo. Always contains 5 (g_minstagib_ammo_drop) shots. @@ -1072,6 +1098,30 @@ strength: "wind field", "gravity field": amount of force per second to apply. "d falloff: "gravity field": 0 means no falloff, 1 means linear falloff (zero at the outside), 2 means inverted linear falloff (zero at the inside) */ +/*QUAKED trigger_keylock (.0 .5 .8) ? - - - GOLD_KEY SILVER_KEY +Keylock trigger. Must target other entities. +This trigger will trigger target entities when all required keys are provided. +-------- KEYS -------- +wait: prevent triggering again for this amount of time (default: 5) - applies to target2, target3, target4. +sounds: 1 to play misc/secret.wav, 2 to play misc/talk.wav, 3 to play misc/trigger1.wav +target: trigger all entities with this targetname when triggered and all keys have been given to it, then remove this trigger +target2: trigger all entities with this targetname when triggered without giving it all the required keys. +target3: trigger all entities with this targetname when triggered with GOLD_KEY missing (requires GOLD_KEY spawnflag) +target4: trigger all entities with this targetname when triggered with SILVER_KEY missing (requires SILVER_KEY spawnflag) +message: print this message to the player who activated the trigger when all needed keys have been given. +message2: print this message to the player who activated the trigger when not all of the needed keys have been given. +noise: sound to play when lock gets unlocked (default: see sounds) +noise1: sound to play when only one of the needed key was used (default: misc/decreasevalue.wav) +noise2: sound to play when a key is missing (default: misc/talk.wav) +killtarget: remove all entities with this targetname when triggered with all the needed keys. +-------- SPAWNFLAGS -------- +GOLD_KEY: causes the door to open only if the activator holds a gold key. +SILVER_KEY: causes the door to open only if the activator holds a silver key. +---------NOTES---------- +If spawned without any key specified, this trigger will remove itself. +message2 and noise2 will be resent to the player every 2 seconds while he is in the trigger zone. +*/ + /*QUAKED trigger_multiple (.5 .5 .5) ? NOTOUCH ALLENTS INVERT_TEAM - - - - - NOSPLASH Variable sized repeatable trigger. Must be targeted at one or more entities. If "health" is set, the trigger must be killed to activate each time. -------- KEYS -------- -- 2.39.2