void func_ladder_init(entity this)
{
- trigger_init(this);
+ EXACTTRIGGER_INIT;
+ BITSET_ASSIGN(this.effects, EF_NODEPTHTEST);
func_ladder_link(this);
setthink(this, func_ladder_think);
this.nextthink = time;
{
SetMovedir(this);
- trigger_init(this);
-
+ EXACTTRIGGER_INIT;
+ BITSET_ASSIGN(this.effects, EF_NODEPTHTEST);
this.active = ACTIVE_ACTIVE;
this.use = trigger_push_use;
settouch(this, trigger_push_touch);
this.setactive(this, ACTIVE_TOGGLE);
}
-bool autocvar_g_triggers_debug = true;
-
-void trigger_init(entity this)
-{
- string m = this.model;
- EXACTTRIGGER_INIT;
- if(autocvar_g_triggers_debug)
- {
- if(m != "")
- {
- precache_model(m);
- _setmodel(this, m); // no precision needed
- }
- setorigin(this, this.origin);
- if(this.scale)
- setsize(this, this.mins * this.scale, this.maxs * this.scale);
- else
- setsize(this, this.mins, this.maxs);
- }
-
- if(autocvar_g_triggers_debug)
- BITSET_ASSIGN(this.effects, EF_NODEPTHTEST);
-}
-
void trigger_link(entity this, bool(entity this, entity to, int sendflags) sendfunc)
{
setSendEntity(this, sendfunc);