![]() |
Warn Player - Printable Version +- Mirage Source (https://mirage-engine.uk/forums) +-- Forum: Mirage Source (Nostalgia) (https://mirage-engine.uk/forums/forumdisplay.php?fid=61) +--- Forum: Archive (2006-2011) (https://mirage-engine.uk/forums/forumdisplay.php?fid=18) +---- Forum: Source Code Development (https://mirage-engine.uk/forums/forumdisplay.php?fid=51) +----- Forum: Mirage Source 4 (Visual Basic 6) (https://mirage-engine.uk/forums/forumdisplay.php?fid=44) +------ Forum: Tutorials (https://mirage-engine.uk/forums/forumdisplay.php?fid=13) +------ Thread: Warn Player (/showthread.php?tid=2178) |
Warn Player - skillzalot - 24-09-2008 Ok this is my first tutorial. This works with the newest version of ms4 so ya. C&P 1 out of 5 to add. This is an edit of NEans Jail command Client Side Find Code: CGetClasses = 1 Under Add Code: CWarnPlayer Find Code: ' // Mapper Admin Commands // Above Add Code: ' Warn player Thats all for client Server side Find Code: CGetClasses = 1 Under Add Code: CWarnPlayer Under Code: ' :::::::::::::::::::::: Add Code: ' :::::::::::::::::::::::: For admin panel button make a label called btnwarn in it add Code: If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then There you go all done. This warns the player that he is breaking a rule and to stop doing whatever he is doing. Enjoy. Post all comments and criticism here Re: Warn Player - Nean - 24-09-2008 It's good, but basic. What would be a nice addition, is to make a .ini file or something, that checks to see if hte player has been warned before. If so then it carries, a certain action. Then on the third strike, they get a ban. Nevertheless, a good first tut. Re: Warn Player - Egon - 24-09-2008 I'd just add a warning stat to the player.ini and have it check that. Every time you warn them it would increase by one and once it reaches three you'd get kicked or banned. Re: Warn Player - Rian - 24-09-2008 You could also use DFAs System Time tut and do things like reducing the players warning level by 1 like every week or 3 days or something. I've been doing much thinking regarding bans, ban times, and warnings and stuff lately. Re: Warn Player - Nean - 24-09-2008 Egon Wrote:I'd just add a warning stat to the player.ini and have it check that. Every time you warn them it would increase by one and once it reaches three you'd get kicked or banned. What functions would you use? Getvar and putvar? Re: Warn Player - Mattyw - 24-09-2008 Don't forget ability to give a reason for Warning. =-p Re: Warn Player - Egon - 26-09-2008 Well first you'd have to use GetVar to make sure they aren't going to match or pass the number for kicking or banning or whatever.. Then PutVar to set the value. It's not all that hard. |