Files
src/miniquake2/game/world/triggers.ml
Provides miniquake2 game world triggers facilities for this project.
- Package
miniquake2.game.world.triggers- Reachable
- Yes
Imports
Declarations
# enableTrigger
function enableTrigger(entity, other, activator, world)
Return the enable trigger value.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# gravityTouch
function gravityTouch(entity, other, world)
Handle gravity.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# hurtTouch
function hurtTouch(entity, other, world)
Handle hurt.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# hurtUse
function hurtUse(entity, other, activator, world)
Use hurt.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# initTrigger
function initTrigger(entity, world)
Initialize trigger.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# monsterJumpTouch
function monsterJumpTouch(entity, other, world)
Handle monster jump.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# multiTrigger
function multiTrigger(entity, world)
Return the multi trigger value.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# multiWait
function multiWait(entity, world)
Return the multi wait value.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# pushTouch
function pushTouch(entity, other, world)
Handle push.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_always
function SP_trigger_always(entity, world)
Spawn trigger always.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_counter
function SP_trigger_counter(entity, world)
Spawn trigger counter.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_gravity
function SP_trigger_gravity(entity, world)
Spawn trigger gravity.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_hurt
function SP_trigger_hurt(entity, world)
Spawn trigger hurt.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_key
function SP_trigger_key(entity, world)
Spawn trigger key.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_monsterjump
function SP_trigger_monsterjump(entity, world)
Spawn trigger monsterjump.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_multiple
function SP_trigger_multiple(entity, world)
Spawn trigger multiple.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_once
function SP_trigger_once(entity, world)
Spawn trigger once.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_push
function SP_trigger_push(entity, world)
Spawn trigger push.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# SP_trigger_relay
function SP_trigger_relay(entity, world)
Spawn trigger relay.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnAlways
function spawnAlways(entity, world)
Spawn always.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnCounter
function spawnCounter(entity, world)
Spawn counter.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnGravity
function spawnGravity(entity, world)
Spawn gravity.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnHurt
function spawnHurt(entity, world)
Spawn hurt.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnKey
function spawnKey(entity, world)
Spawn key.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnMonsterJump
function spawnMonsterJump(entity, world)
Spawn monster jump.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnMultiple
function spawnMultiple(entity, world)
Spawn multiple.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnOnce
function spawnOnce(entity, world)
Spawn once.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnPush
function spawnPush(entity, world)
Spawn push.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# spawnRelay
function spawnRelay(entity, world)
Spawn relay.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# touchMulti
function touchMulti(entity, other, world)
Handle multi.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# useCounter
function useCounter(entity, other, activator, world)
Use counter.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# useKey
function useKey(entity, other, activator, world)
trigger_key. Inventory and cooperative power-cube policy remain outside the world package through resolve/has/consume callbacks.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# useMulti
function useMulti(entity, other, activator, world)
Use multi.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source
# useRelay
function useRelay(entity, other, activator, world)
Use relay.
| Parameter | Type | Default | Description |
|---|
entity | dynamic | — | entity value consumed by this operation. |
other | dynamic | — | other value consumed by this operation. |
activator | dynamic | — | activator value consumed by this operation. |
world | dynamic | — | world value consumed by this operation. |
View source