gettouch(this)(this, actor);
}
+void item_setactive(entity this, int act)
+{
+ int old_status = this.active;
+ if(act == ACTIVE_TOGGLE)
+ this.active = (this.active == ACTIVE_ACTIVE) ? ACTIVE_NOT : ACTIVE_ACTIVE;
+ else
+ this.active = act;
+
+ if(this.active != old_status)
+ Item_Show(this, ((this.active == ACTIVE_ACTIVE) ? 1 : -1));
+}
+
void StartItem(entity this, entity def)
{
if (def.m_spawnfunc_hookreplace)
if(this.targetname != "" && (this.spawnflags & 16))
this.use = item_use;
+ this.setactive = item_setactive;
+ this.active = ACTIVE_ACTIVE;
+
if(autocvar_spawn_debug >= 2)
{
// why not flags & fl_item?