AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   Constant Names v1.2 (https://forums.alliedmods.net/showthread.php?t=28217)

KoST 05-09-2006 19:55

Constant Names v1.2
 
1 Attachment(s)
Constant Names v1.2
  • Description:
    This plugin allows admins to define (SteamID -> PlayerName) pairs in a config file. listed players can't change their name and are forced to have the defined one.

    Special Feature:
    players names are only changed serverside not clientside!
    an example: a player previously named 'Stan' is forced by this plugin to have the name '[UCT]Stan'. on the server the player has now the name '[UCT]Stan', but if he types 'name' in console to show his name he would get the following output: (although his playername is currently '[UCT]Stan')
    "name" is "Stan"
    which means that if he then connects to another server his name would be 'Stan' again.

  • Setup:
    edit new file: configs/constant_names.ini:
    here you can define which player(SteamID) should have which name.
    here is an example 'constant_names.ini' file:
    Code:

    STEAM_0:0:123459 "Sam"
    STEAM_0:0:123456 "KoST"
    STEAM_0:0:99662 "Elch"

    in this case for ex. the player with steam_id:[STEAM_0:0:123456] will be forced to have the playername 'KoST' and he is not able to change it.
  • Info
    if you need more than 100 predefined (SteamID -> PlayerName) pairs you must edit the sma file of this plugin and recompile:
    Code:
    // set this to a higher value if you need more predefined users in you config file #define MAX_USERS 100 // you can also modify the default config file name if needed #define CONFIG_FILE "constant_names.ini"

  • Required Modules:
    this plugin needs no additional modules
  • CVars
    none
  • Commands
    none

    ChangeLog:
  • 10. May 2006 - v1.0:
    --added: some code to empty file..
  • 10. May 2006 - v1.1:
    --changed: config file is now precached !
  • 10. May 2006 - v1.2:
    --added: some text output

BACARRA 05-09-2006 20:00

can you make it so that when they enter the server it will automatically write their names in the config file

v3x 05-09-2006 20:12

You should make it so that it loads the file once when the map loads. Then you should store the names/ids in global variables and check from there.

Here's a good example: http://forums.alliedmods.net/showthr...=237447#244642

KoST 05-09-2006 20:12

@BACARRA: adding this would cause all players to be doomed to have the name they had when they first connected to the server, you want that?

thx v3x :up:

SweatyBanana 05-09-2006 20:14

Would be a good idea...and add an option for an admin to change their name.

BACARRA 05-09-2006 20:14

yes pls if that would be possible.

KoST 05-09-2006 20:19

ok, now everybody is requesting to add stuff...
i think i will rewrite this using nvault to store names, this approach is better to get all your requests done !

[edit] i'm not going to add nvault
http://webuser.hs-furtwangen.de/%7Ek...t2/fixfox7.gif

SubStream 05-09-2006 20:22

I like the simplicity of it. Steam ID... name... that makes it easy to just do what u want to do without worrying about anything else to set up. GJ nice work.

BACARRA 05-09-2006 20:28

it be more simple if it wrote it on its own. imagine having to type out over 2000 people steam ids and names and yes it is a good plugin

SubStream 05-09-2006 20:40

Quote:

Originally Posted by BACARRA
it be more simple if it wrote it on its own. imagine having to type out over 2000 people steam ids and names and yes it is a good plugin

Thats what Suicid3s amx_onename plugin is for.... :(


All times are GMT -4. The time now is 01:22.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.