self.nextthink = time;
}
-void ons_DelayedLinkSetup()
-{SELFPARAM();
+void ons_DelayedLinkSetup(entity this)
+{
self.goalentity = find(world, targetname, self.target);
self.enemy = find(world, targetname, self.target2);
if(!self.goalentity) { objerror("can not find target\n"); }
onslaught_updatelinks();
// Use targets now (somebody make sure this is in the right place..)
- setself(this.owner);
- activator = this;
- WITHSELF(this, SUB_UseTargets());
- setself(this);
+ SUB_UseTargets(this.owner, this, NULL);
this.owner.waslinked = this.owner.islinked;
if(this.owner.model != "models/onslaught/controlpoint_pad.md3")
if(!self.owner.islinked)
self.owner.team = 0;
- setself(self.owner);
- activator = self;
- SUB_UseTargets ();
- setself(this);
+ SUB_UseTargets(self.owner, self, NULL);
self.owner.team = t;
onslaught_updatelinks();
// Use targets now (somebody make sure this is in the right place..)
- setself(self.owner);
- activator = self;
- SUB_UseTargets ();
- setself(this);
+ SUB_UseTargets(self.owner, self, NULL);
self.SendFlags |= CPSF_SETUP;
}
onslaught_updatelinks();
- activator = this;
- SUB_UseTargets(); // to reset the structures, playerspawns etc.
+ SUB_UseTargets(this, this, NULL); // to reset the structures, playerspawns etc.
CSQCMODEL_AUTOUPDATE(this);
}
-void ons_DelayedControlPoint_Setup()
-{SELFPARAM();
+void ons_DelayedControlPoint_Setup(entity this)
+{
onslaught_updatelinks();
// captureshield setup
onslaught_updatelinks();
}
-void ons_DelayedGeneratorSetup()
-{SELFPARAM();
+void ons_DelayedGeneratorSetup(entity this)
+{
// bot waypoints
waypoint_spawnforitem_force(self, self.origin);
self.nearestwaypointtimeout = 0; // activate waypointing again
return false;
}
-void ons_MonsterSpawn_Delayed()
-{SELFPARAM();
- entity e, own = self.owner;
+void ons_MonsterSpawn_Delayed(entity this)
+{
+ entity own = self.owner;
- if(!own) { remove(self); return; }
+ if(!own) { remove(this); return; }
if(own.targetname)
{
- e = find(world, target, own.targetname);
+ entity e = find(world, target, own.targetname);
if(e != world)
{
own.team = e.team;
- activator = e;
- own.use();
+ own.use1(own, e, NULL);
}
}
- remove(self);
+ remove(this);
}
MUTATOR_HOOKFUNCTION(ons, MonsterSpawn)
return false;
}
-void ons_TurretSpawn_Delayed()
-{SELFPARAM();
- entity e, own = self.owner;
+void ons_TurretSpawn_Delayed(entity this)
+{
+ entity own = self.owner;
if(!own) { remove(self); return; }
if(own.targetname)
{
- e = find(world, target, own.targetname);
+ entity e = find(world, target, own.targetname);
if(e != world)
{
own.team = e.team;
own.active = ACTIVE_NOT;
- activator = e;
- own.use();
+ own.use1(own, e, NULL);
}
}
ScoreRules_basics_end();
}
-void ons_DelayedInit() // Do this check with a delay so we can wait for teams to be set up
+void ons_DelayedInit(entity this) // Do this check with a delay so we can wait for teams to be set up
{
ons_ScoreRules();