Raised This Month: $51 Target: $400
 12% 

Admin announce


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bdn
Junior Member
Join Date: Apr 2005
Old 08-01-2005 , 13:23   Admin announce
Reply With Quote #1

Found this plugin:

Code:
#include <amxmodx> #include <amxmisc> public plugin_init()     register_plugin("Admin enter","0.1","v3x") new file[]="admins.txt" new steamid[64] new msg[64] public client_authorized(id) {     new authid[32]     get_user_authid(id,authid,31)     new folder[64]     get_configsdir(folder,63)     new filestr[64]     format(filestr,63,"%s/%s",folder,file)     new line[1024],flags[1024],a=0,pos=0,len=0,i     while((read_file(file,pos,line,1023,a))) {         if((!equal(line,"//",2)) && (strlen(line) > 0)) { // Checks for comments             parse(line,steamid,63)             len++         }         pos++     }     for(i=0;i<len;i++) {         if(equali(authid,steamid[i])) {             flags[i] = get_user_flags(steamid[i])             format(msg,63,"Steam ID: %s has joined with flags: %s",steamid[i],flags[i])             // Edit this line (if needed) ^             if(equali(authid,"STEAM_0:0:1290192")) { // Your Steam ID                 set_hudmessage(0,255,0,0.10,0.55,0,6.0,6.0,0.5,0.15,3)                 show_hudmessage(id,msg)             }         }     }     return PLUGIN_CONTINUE }

But i doesen't work as i want to, i want i to say: Admin: bdn enter the server.

How do i do that?.
bdn is offline
Xanimos
Veteran Member
Join Date: Apr 2005
Location: Florida
Old 08-01-2005 , 14:12  
Reply With Quote #2

Ill make one up here for ya.
Code:
#include <amxmodx> #include <amxmisc> public plugin_init() {     register_plugin("Admin Announce","1.0","$uicid3") } public client_putinserver(id) {     if(is_user_admin(id))  //Will work for all admins     {         new szName[36], szMsg[66]         get_user_name(id,szName,35)         format(szMsg,65,"Admin %s has Joined.",szName)         set_hudmessage(0,255,0,0.10,0.55,0,6.0,6.0,0.5,0.15,3)         show_hudmessage(0,szMsg)     } }
Xanimos is offline
Send a message via AIM to Xanimos Send a message via MSN to Xanimos
bdn
Junior Member
Join Date: Apr 2005
Old 08-01-2005 , 15:08  
Reply With Quote #3

I have more than 1 admin on the server, how do i make so they also are displayed?
bdn is offline
D_Hawk
Veteran Member
Join Date: Apr 2005
Location: No
Old 08-01-2005 , 15:18  
Reply With Quote #4

Compile it multiple times with different Steam IDs.
__________________
User has abandoned this account.
D_Hawk is offline
Send a message via ICQ to D_Hawk Send a message via AIM to D_Hawk Send a message via MSN to D_Hawk Send a message via Yahoo to D_Hawk
bdn
Junior Member
Join Date: Apr 2005
Old 08-01-2005 , 15:27  
Reply With Quote #5

ya but are there no other way to do it?

edit: got an error.

Code:
//// ajoin1.sma
// \\server\HLServer\cstrike\addons\amxmodx\scripting\ajoin1.sma(19) : error 017
: undefined symbol "msg"
//
// 1 Error.
// Could not locate output file compiled\ajoin1.amx (compile failed).
//
// Compilation Time: 0,45 sec
bdn is offline
Xanimos
Veteran Member
Join Date: Apr 2005
Location: Florida
Old 08-01-2005 , 15:56  
Reply With Quote #6

Fixed/Edited above...will work for all admins now(i Thought you only wanted one admin
Xanimos is offline
Send a message via AIM to Xanimos Send a message via MSN to Xanimos
bdn
Junior Member
Join Date: Apr 2005
Old 08-01-2005 , 16:07  
Reply With Quote #7

thanks.
bdn is offline
D_Hawk
Veteran Member
Join Date: Apr 2005
Location: No
Old 08-01-2005 , 16:09  
Reply With Quote #8

Code:
#include <amxmodx> #include <amxmisc> public plugin_init() {     register_plugin("Admin Announce","1.0","$uicid3") } public client_putinserver(id) {     if(is_user_admin(id))  //Will work for all admins     {         new szName[36], szMsg[66]         get_user_name(id,szName,35)         format(szMsg,65,"Admin %s has Joined.",szName)         set_hudmessage(0,255,0,0.10,0.55,0,6.0,6.0,0.5,0.15,3)         show_hudmessage(0,szMsg)     } }
__________________
User has abandoned this account.
D_Hawk is offline
Send a message via ICQ to D_Hawk Send a message via AIM to D_Hawk Send a message via MSN to D_Hawk Send a message via Yahoo to D_Hawk
bdn
Junior Member
Join Date: Apr 2005
Old 08-01-2005 , 19:16  
Reply With Quote #9

Code:
#include <amxmodx> #include <amxmisc> public plugin_init() {     register_plugin("Admin Announce","1.0","$uicid3") } public client_putinserver(id) {     if(is_user_admin(id))  //Will work for all admins     {         new szName[36], szMsg[66]         get_user_name(id,szName,35)         format(szMsg,65,"Admin %s has Joined.",szName)         set_hudmessage(0,255,0,0.10,0.55,0,6.0,6.0,0.5,0.15,3)         show_hudmessage(0,szMsg)     } }


How do i put in so the admin also will glow when connect? i have the admin_glow plugin. the command is: amx_glow name silver
bdn is offline
D_Hawk
Veteran Member
Join Date: Apr 2005
Location: No
Old 08-01-2005 , 20:33  
Reply With Quote #10

Code:
#include <amxmodx> #include <amxmisc> public plugin_init() {     register_plugin("Admin Announce","1.0","$uicid3") } public client_putinserver(id) {     if(is_user_admin(id))  //Will work for all admins     {         new szName[36], szMsg[66]         get_user_name(id,szName,35)         format(szMsg,65,"Admin %s has joined.",szName)         set_hudmessage(0,255,0,0.10,0.55,0,6.0,6.0,0.5,0.15,3)         show_hudmessage(0,szMsg)         server_cmd("amx_show_activity 0")         client_cmd(id,"amx_glow %s silver", szName)         server_cmd("amx_show_activity 2")     } }

BTW, that's the cheap way out. It probably won't even work since it makes them do that before they're actually in game.
__________________
User has abandoned this account.
D_Hawk is offline
Send a message via ICQ to D_Hawk Send a message via AIM to D_Hawk Send a message via MSN to D_Hawk Send a message via Yahoo to D_Hawk
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:36.


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