| closedPlayer name FIX |
| Started by RollinDeath on 03-19-2009, 12:21 AM |
Threads: 6
Joined: Nov 2007
I would like to ask that some one make a plug in that will ask a "Player" to change their name. Make a message big enough for them to see it.. obvious like and then use messagemode to allow the to type in a small number of letters... Maybe 15 or so. Then after they type the new name and hit enter the server will use amx_nick to change the players name and then allow the player to play. I do not think the player should be blocked from the game or nothing but he should be required to hit enter and start playing IF his or her name is "Player"
Threads: 6
Joined: Nov 2007
OH !!!!rnrn here is a feature I would like as well. IF they do not enter anything then force the name change to their STEAM ID!
Threads: 15
Joined: Mar 2007
I actually did this for someone as a private request not to long ago. The concept is a little different though, it warns the player and if after x seconds they don't change it, it will change their name to one from a list. If this works for you, I'll throw it up add the steam id usage as well.
Threads: 75
Joined: Nov 2007
i made this long ago, it will show "Player" that theres a chat command called /name and that command will show a motd that has a guid for how to change there name.. You will need a file called name_help.txt in the root folder where e.g server.cfg is found, with info about how to change the damn name...rnrn
#include <amxmodx>rn#include <dodx>rnrn#define PLUGIN "Client help"rn#define VERSION "1.0 by Dr.G - www.clan-go.net"rn#define AUTHOR "Dr.G"rnrn//FILErn#define HELPNAME "name_help.txt"rnrnnew p_onrnrnpublic plugin_init() rn{rn register_plugin(PLUGIN, VERSION, AUTHOR)rn register_cvar("client_help_stats", VERSION, FCVAR_SERVER|FCVAR_SPONLY)rn p_on = register_cvar("client_help", "1") //Plugin on/off | 1=on 0=offrn rn register_clcmd("say /name", "NameHelp")rn register_clcmd("say_team /name", "NameHelp")rn rn if(!file_exists(HELPNAME))rn set_fail_state("[Client help]name_help.txt does not exist!")rn}rnpublic client_putinserver(id)rn{rn new name[33]rn get_user_name(id,name,sizeof name -1)rn rn if(equal(name, "Player") || equal(name, "(1)Player") || equal(name, "(2)Player") || equal(name, "(3)Player") || equal(name, "(4)Player") || equal(name, "(5)Player"))rn set_task(10.0,"ShowMsg",id)rn}rnpublic dod_client_changeteam(id)rn{rn new p_name[33]rn get_user_name(id,p_name,sizeof p_name -1)rn rn if(equal(p_name, "Player") || equal(p_name, "(1)Player") || equal(p_name, "(2)Player") || equal(p_name, "(3)Player") || equal(p_name, "(4)Player") || equal(p_name, "(5)Player"))rn set_task(5.0,"ShowMsg",id)rn} rnpublic NameHelp(id)rn{rn if(get_pcvar_num(p_on))rn show_motd(id, HELPNAME,"Help screen | Name change")rn}rnpublic ShowMsg(id)rn{rn set_hudmessage(75, 223, 179, -1.0, -1.0, 0, 6.0, 30.0)rn show_hudmessage(id, "Need help Changeing your name???^nSay /name in chat to see how to!^n^n Cheers!")rn}rnrnrnThis is how my name_help.txt goes:rnrn<html>rn<body bgcolor="#303020" text="#c1b689"> rn <p>rn<font face="Arial">rn<h3>CONSOLErn<hr>rn<h4>To open your console press ½ or § its the same key! Right below Escrn<hr>rn<h3>NAME CHANGErn<hr>rn<h4>Open your console - Type: name "newname"rn<h4>NOTE if you want spaces in your name use % where you want the space to be!rn<h4>I.g. name My%New%Name will set your name to "My New Name" rn<hr>rn</h4>rn</body>rn</html>
Threads: 6
Joined: Nov 2007
Nice and thank you,nnI am doing some learning and hopefully be adding more to this plug in.
Threads: 75
Joined: Nov 2007
cool.. let me see what you end up with :)
Threads: 6
Joined: Nov 2007
dodsynthetic,rnI apologize for not Thank you sooner for your offer. I am all open for suggestions and could really use expert opinions. rnrnDr.G,rnSo far this is all I could figure out and it has been fun.rnrnI am considering a few things like adding back the MOTD but for now I did good getting the menu to work at all. So Please let me know what you think and any suggestions would be appreciated on any errors I have made.
Threads: 15
Joined: Mar 2007
OK, I've put it up here: https://www.dodplugins.net/forums/showthread.php?p=12491#post12491

