Jump to content

[IDEA][Request] Player name Changer....


DazzaJay

Recommended Posts

I just had the best idea.....

A Script, that can run on a server....

So that if somone joins with the name "Player" it will change thier name to thier MTAbeta login name.

Because at the moment, we just have a script that kicks "Player" but some people wont know why because they dont know english.

But yeah...

in thoery...

has joined the game

's name was changed to by server.

and so on.

But yeah, it would be only to run if the Players name wsa "Player"

so people with proper names dont get thier names changed to thier login names.

Link to comment

so you're basically requesting access to the mtabeta/community.mtasa.com-database to get a nick by serial? I doubt they'll do, it's right now just available to check if a certain serial is valid and not what nick is assigned to a serial.

Besides... just let them change their nick or set a 60 second-timer to kick them if they haven't changed until then...

Link to comment

well, here is the thing, i dont belive it needs access to the mta beta, becaus i can just go to my servers admin panel and see thier mta beta login names in it, at the click of a button.

so i figure if it can, then a script can, that runs client side, if client joins with "Player" the client side script changes thier name to "Jim117" or whatever his login name is.

the way we have it at the moment is simple, we have a 5-second kick timer on "player" with kick reason of "Change your name before returning"

but a lot of people are either arrogant, ignorant, or just plain dont know english, and try over and over and over again, till they give up....

like, heres an example....

(relayed from BOTH Pothole Studios Servers to IRC:)

[06:36 AM] [PS]DM-SVR1: * Player joined the server.

[06:36 AM] [PS]DM-SVR1: * Player left the server. (Kicked)

[06:36 AM] [PS]DM-SVR1: * Player joined the server.

[06:36 AM] [PS]DM-SVR1: * Player left the server. (Kicked)

[06:36 AM] [PS]DM-SVR1: * Player joined the server.

[06:36 AM] [PS]DM-SVR1: * Player left the server. (Kicked)

[06:37 AM] [PS]DM-SVR2: * Player joined the server.

[06:37 AM] [PS]DM-SVR2: * Player left the server. (Kicked)

[06:37 AM] [PS]DM-SVR2: * Player joined the server.

[06:37 AM] [PS]DM-SVR2: * Player left the server. (Kicked)

[06:37 AM] [PS]DM-SVR2: * Player joined the server.

[06:37 AM] [PS]DM-SVR2: * Player left the server. (Kicked)

[06:37 AM] [PS]DM-SVR2: * Player joined the server.

[06:37 AM] [PS]DM-SVR2: * Player left the server. (Kicked)

its like.... HOW STUPID CAN YOU BE.

even a person who dosent know english should know by atleast the third kick that the server dosent allow them.

Link to comment

I have a resource which changes players names to remove the characters ' and " from names as they mess up SQLite. Also It changes 'Player' to N00B plus some random integer.

Don't kick people just because they're new, but mock them by all means.

for example:

    local oldName = getClientName( source ) 
    math.randomseed( getTickCount () ) 
        math.random(100); math.random(100); moo = math.random(100) 
    newName = string.gsub( newName , "Player", "N00B"..tostring(moo)) 
    setClientName( source, newName ) 

Oh and trust me, people will come back over and over and over again. Take it as a complement :P

Link to comment
function checkName() 
    if getClientName ( source ) == "Player" then 
        setClientName ( source, getPlayerUserName ( source ) ) 
    end 
end 
addEventHandler ( "onPlayerJoin", getRootElement(), checkName ) 

this should do it (not tested)

Link to comment

I agree!

Lets start a.....

NOOBATHON!

well.. this is from my servers IRC yesterday....

we havnt got the name changer or anything, but i can see the effects of people who have it....

11:18 AM] [PS]DM-SVR2: * N00B35 joined the server.

[11:18 AM] [PS]DM-SVR2: * N00B35 left the server. (Quit)

[11:19 AM] [PS]DM-SVR2: * N00B35 joined the server.

[11:20 AM] [PS]DM-SVR2: * N00B35 left the server. (Quit)

[11:20 AM] [PS]DM-SVR2: * N00B35 joined the server.

[11:20 AM] [PS]DM-SVR2: N00B35: hi

[11:20 AM] [PS]DM-SVR2: N00B35: hi

[11:21 AM] [PS]DM-SVR2: * N00B35 left the server. (Quit)

Link to comment

lol yes that's my fault, but they deserve it.

tbh I just wanted something that meant my SQL db wouldn't be full of people called 'Player', also I presumed it'd make people want to set themselves proper names.

Originally it was just to clean out those nasty characters but what the hey :)

Link to comment
function checkName() 
    if getClientName ( source ) == "Player" then 
        setClientName ( source, getPlayerUserName ( source ) ) 
    end 
end 
addEventHandler ( "onPlayerJoin", getRootElement(), checkName ) 

this should do it (not tested)

Tested, works Brilliantly.

Link to comment

Think this should work?

function checkName() 
    if getClientName ( source ) =~ getPlayerUserName ( source ) then 
        setClientName ( source, getPlayerUserName ( source ) ) 
    end 
end 
addEventHandler ( "onPlayerJoin", getRootElement(), checkName ) 

This will stop them for using an other name (fake) then their username.

Link to comment
Think this should work?
function checkName() 
    if getClientName ( source ) =~ getPlayerUserName ( source ) then 
        setClientName ( source, getPlayerUserName ( source ) ) 
    end 
end 
addEventHandler ( "onPlayerJoin", getRootElement(), checkName ) 

This will stop them for using an other name (fake) then their username.

I don't like the idea of that, what if I want to play with my clan's tag and my account name is 'norby89'?

Link to comment

agreed, i have a few variations of my name, [PS]DazzaJay[AU], DazzaJay, [PHS]Dan[AU], Daniel-Jay.

like, in my own server, i often change to a name like "Dax" or "Ichigo" or somthing, so im not wearing my clan tag, or showing my name (helps to inspect cheaters better if they think there isnt an admin in there)

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...