[REQ] Add .ini file
Sup, could you exchange "new const messages" with .ini file? :
PHP Code:
#include <amxmodx>
new g_MsgSayText, Msg
new const messages[][] =
{
/*MESSAGE*/
}
public plugin_init()
{
set_task( 60.0, "Show_ColorMessage", _, _, _, "b" )
g_MsgSayText = get_user_msgid( "SayText" )
}
public Show_ColorMessage()
{
if( !get_playersnum() ) return
ColorMessage( 0, messages[ Msg ] )
if( ++Msg == sizeof messages ) Msg = 0
}
ColorMessage( const iReceiver, const iSender = 1, const fmt[], any:Click post title for more details)
{
new szMessage[ 192 ]
vformat( szMessage, charsmax( szMessage ), fmt, 4 )
message_begin( iReceiver ? MSG_ONE_UNRELIABLE : MSG_BROADCAST, g_MsgSayText, _, iReceiver )
&nbs p; write_byte( iSender )
write_string( szMessage )
message_end()
}
Orignal From: [REQ] Add .ini file
Post a Comment