Raised This Month: $ Target: $400
 0% 

What's wrong with this?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 10-20-2005 , 21:42   What's wrong with this?
Reply With Quote #1

I can't seem to find the problem.. People have been saying they've been getting "bad loads" with it:
Code:
#include <amxmodx> #define PLUGIN  "Connect Announce" #define VERSION "0.2b" #define AUTHOR  "v3x" new g_iMsgSayText, g_szSoundFile[] = "buttons/blip1.wav"; public plugin_init() {     register_plugin(PLUGIN, VERSION, AUTHOR);     register_cvar("announce_mode","3");     register_cvar("announce_sound","1");     g_iMsgSayText = get_user_msgid("SayText"); } /* announce_mode <0|1|2|3> 0 - Off 1 - Connect announce only 2 - Disconnect announce only 3 - Both announce_sound <0|1> 0 - No sound 1 - Sound */ public plugin_precache() {     precache_sound(g_szSoundFile); } public client_authorized(id) {     new iMode = get_cvar_num("announce_mode");         if(is_user_bot(id) || iMode == 0 || iMode == 2)         return PLUGIN_CONTINUE;     new szUserName[33];     get_user_name(id, szUserName, 32);     new iPlayers[32], iNum, i;     get_players(iPlayers, iNum);     for(i = 0; i <= iNum; i++)     {         new x = iPlayers[i];         if(!is_user_connected(x) || is_user_bot(x)) continue;         if(get_cvar_num("announce_sound") == 1)             client_cmd(x, "spk %s", g_szSoundFile);         new szMessage[164];         format(szMessage, 163, "^x04%s connected", szUserName);         message_begin( MSG_ONE, g_iMsgSayText, {0,0,0}, x );         write_byte  ( x );         write_string( szMessage );         message_end ();     }     return PLUGIN_CONTINUE; } public client_disconnect(id) {     new iMode = get_cvar_num("announce_mode");         if(is_user_bot(id) || iMode == 0 || iMode == 1)         return PLUGIN_CONTINUE;     new szUserName[33];     get_user_name(id, szUserName, 32);     new iPlayers[32], iNum, i;     get_players(iPlayers, iNum);     for(i = 0; i <= iNum; i++)     {         new x = iPlayers[i];         if(!is_user_connected(x) || is_user_bot(x)) continue;         if(get_cvar_num("connect_sound") == 1)             client_cmd(x, "spk %s", g_szSoundFile);         new szMessage[164];         format(szMessage, 163, "^x04%s disconnected", szUserName);         message_begin( MSG_ONE, g_iMsgSayText, {0,0,0}, x );         write_byte  ( x );         write_string( szMessage );         message_end ();     }     return PLUGIN_CONTINUE; }
v0.1 is in the Approved Plugins section if you need to see it.
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
 


Thread Tools
Display Modes

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 23:52.


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