Forums Index >> Modding >> DJ wings
Page : <1> :
Dark y did u change ur name? And I thought u quit TT
What? That is Dark?
@ Moderator
Please look into this matter I need to know.
Joe quit f***ing asking my name because I wanted to f***
No need for that language. -KBC
Last edited: Thursday, March 03, 2005 at 6:30:15 PM
@Tank,
Im assuming that is a power up that kicks demos? Looks like it.
I don't know if the code works properly. But you can try this...wait, DEMOS can't join player hosted servers, can they?
.....
function kick::onEnter(%db,%this,%tank)
{
Centerprintall("Bye, demos!",5,1 );
$len = clientgroup.getCount();
for(%i=0; %i<$len; %i++)
{
%client = clientgroup.getObject(%i);
if(%client.namebase.strstr("DEMO"))
%client.player.delete("DemoBGone Script 1.1 kicked you. Do not come back.");
}
Yeah, put that ontop of your mission file, and make a datablock for it. You can do that right?
Last edited: Friday, March 04, 2005 at 6:41:55 AM
I don't think that very nice(if it even work)... If you don't like DEMOs use team playing modes.
You don't have to let go of one rope before grabbing the other. But you'll have to let go of one if you want to swing forward.
Yeah. What's bad in DEMOs? I always let demos play in my mod. Becouse it' free-for-all game.
Who remembers Hardly Scrum mod? :) I'll put it up again soooon...
Last edited: Friday, March 04, 2005 at 9:33:51 AM
Page : <1> :
Ok dj wings said this on a nother thread to kick demos were do I put it
Function PowerUpData::onEnter(%db,%this,%tank)
{
//echo(%tank.client.name @ " enters powerup " @ %this.getId() @ " of type " @ %db.type);
if (%db.type $= "weapon")
{
%choice = getRandom($NumPupTypes-1);
%tank.setProjectile($pupTypes[%choice]);
if (getRandom(10)<=2 && !$Game::SinglePlayer){
%this.schedule(5000,"setDatablock","Heal");
Centerprintall("Bye, demos!",5,1 );
$len = clientgroup.getCount();
for(%i=0; %i<$len; %i++)
{
%client = clientgroup.getObject(%i);
if(%client.namebase.strstr("DEMO"))
%client.player.delete("DemoBGone Script 1.1 kicked you. Do not come back.");
}
}
// schedule say $pupSnds[%choice]
if (isObject(%tank.client))
%tank.client.schedule(1000,"play2D",$pupSnds[%choice]);
}
else if (%db.type $= "health")
{
%tank.hurtMe(-100);
%this.schedule(5000,"setDatablock","TestPowerup");
// schedule say Heal
if (isObject(%tank.client))
%tank.client.schedule(1000,"play2D","ActivateHeal");
}
else if (%db.type $= "ammo")
{
%this.playUserThread(1,1,true);
%tank.setProjectile(%tank.getDataBlock().defaultProjectile);
// schedule say Reload
if (isObject(%tank.client))
%tank.client.schedule(1000,"play2D","ActivateReload");
}
else if (%db.type $= "goal")
{
if ($Game::MissionType $= "Scrum")
{
if (%tank.getFlag() != -1)
{
serverPlay3D(PupOffSound,%this.getTransform());
%flag = %tank.getFlag();
%flag.clearMount();
%flag.setTransform(VectorAdd(pickSpawnPoint(""),"0 0 10"));
%flag.setGoal(pickGoal());
if ($Game::TeamGame)
bottomPrintAll(%tank.client.nameBase SPC "scored a goal for the" SPC %tank.client.team.shortName SPC "team!",4,2);
else
bottomPrintAll(%tank.client.nameBase SPC "scored a goal!",4,2);
%tank.incScore(1,1);
}
}
}
else if (%db.type $= "brain")
{
if ($Game::SinglePlayer)
{
if (%tank.getId() == LocalClientConnection.player.getId())
{
%startScore = strfrap(strswiz($Game::idleText @ "client",12),%tank.client.spscore);
%score = %startScore + $Game::BrainPoints;
%tank.client.spscore = strfrip(strswiz($Game::idleText @ "client",12),%score);
SPScoreGui.setScore(%score);
LocalClientConnection.brains++;
SPBrainCounter.setCount(LocalClientConnection.brains);
LocalClientConnection.lastKillTime = getSimTime(); // delay exit for a moment
// this code currently duplicates code in tank.cs...consolidate??? No, for "security" reasons
%freeLives = mFloor(%score/10000)-mFloor(%startScore/10000);
if (%freeLives>0)
{
alxPlay(SPExtra);
%tank.client.lives = %tank.client.lives + %freeLives;
SPLivesGui.showLives(%tank.client.lives);
}
}
}
}
}