Author Topic: Server IDs  (Read 4779 times)

« Last Edit: May 22, 2010, 12:41:45 AM by Bot »

When a player joins a server they get ID: 0.

Example:

 Host Joined, ID: 0
               
 Player Joined, ID: 1


Download
Edeet. Pointless
« Last Edit: May 21, 2010, 10:04:10 PM by Alphadin »

Cool, but no real point...
Yeah i know... Lol but go ahead and download if you want.

Cool, but no real point...
NINJA: And some poeple will go "Omgz eet is B@dspot plzz give me admin on yur servers!1!111!!!".
Because you have ID 0.
Its not on the player list it says

Player Joined

Player ID: 1 Joined the server!

Pointless add-on, and I just spoon-fed you the the entire script.

Yeah i know... Lol but go ahead and download if you want.
Oh, thought it changed your ID according to what place you joined.
This i still useless. No offense.

I just looked at it, and you copied the code exactly as I gave it to you.

I just looked at it, and you copied the code exactly as I gave it to you.
I didnt understand what code to put in. i already had one but it was messed up.

I didnt understand what code to put in. i already had one but it was messed up.
So because you didn't know what you were doing, it's alright to steal?

So because you didn't know what you were doing, it's alright to steal?
:/ Its not really stealing. I knew how to do it i just asked for some code help.

:/ Its not really stealing. I knew how to do it i just asked for some code help.
Put a "//" and you won't be stealing.











:p

:/ Its not really stealing. I knew how to do it i just asked for some code help.
That's alot of help you got there.



Warning - while you were reading a new reply has been posted. You may wish to review your post.

Don't care.

Let's compare

My code:
Code: [Select]
function getPlayerID(%client)
{
    for(%a = 0; %a < ClientGroup.getCount(); %a++)
if(ClientGroup.getObject(%a) == %client)
    return %a;
}

package IDS
{
function gameConnection::autoAdminCheck(%this)
{
messageAll('',"\c7Player ID: "@ getPlayerID(%this) @" has joined the server!");
return parent::autoAdminCheck(%this);
}
};
activatepackage(IDS);

Your code:
Code: [Select]
function getPlayerID(%client)
{
    for(%a = 0; %a < ClientGroup.getCount(); %a++)
   if(ClientGroup.getObject(%a) == %client)
       return %a;
}

package IDS
{
function gameConnection::autoAdminCheck(%this)
{
messageAll('',"\c7Player ID: "@ getPlayerID(%this) @" has joined the server!");
return parent::autoAdminCheck(%this);
}
};
activatepackage(IDS);

Let's compare

My code:
Code: [Select]
function getPlayerID(%client)
{
    for(%a = 0; %a < ClientGroup.getCount(); %a++)
if(ClientGroup.getObject(%a) == %client)
   return %a;
}

package IDS
{
function gameConnection::autoAdminCheck(%this)
{
messageAll('',"\c7Player ID: "@ getPlayerID(%this) @" has joined the server!");
return parent::autoAdminCheck(%this);
}
};
activatepackage(IDS);

Your code:
Code: [Select]
function getPlayerID(%client)
{
    for(%a = 0; %a < ClientGroup.getCount(); %a++)
   if(ClientGroup.getObject(%a) == %client)
       return %a;
}

package IDS
{
function gameConnection::autoAdminCheck(%this)
{
messageAll('',"\c7Player ID: "@ getPlayerID(%this) @" has joined the server!");
return parent::autoAdminCheck(%this);
}
};
activatepackage(IDS);
No i mean mine was way off. so i just used yours. i could give you credit if you want?

My old one

Code: [Select]
package IDS
{
function GameConnection::LoadMission(%c,%a,%b,%d,%e,%f)
{
if(%client.bl_id == 9088)
{
Messageall(' ',"Player ID: 0 has joined the server!" SPC %say);
}
Parent::LoadMission(%c,%a,%b,%d,%e,%f);
}
};
activatepackage(IDS);

What? Your "old one" doesn't even make sense to what this is.