|
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
|
06-10-2010
, 20:42
Re: random msg
|
#21
|
Quote:
Originally Posted by FlyingHorse
or i could just do this?
PHP Code:
#include <amxmodx>
#include <colorchat>
#define MAX_MSG 4
new const PLUGIN[ ] = "Advertisements"
new const VERSION[ ] = "1.0"
new const AUTHOR[ ] = "FlyingHorse"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
set_task(30.0, "advertisements", id, _, _, _, "b");
}
public advertisements(id)
{
switch (random_num(1, MAX_MSG))
{
case 1:
{
ColorChat(id, RED, "lol")
}
case 2:
{
ColorChat(id, RED, "blah")
}
case 3:
{
ColorChat(id, RED, "Drekes has a ponytail!")
}
case 4:
{
ColorChat(id, RED, "omfg")
}
}
}
|
If you just 'test' your codes then you would know if they worked.
__________________
|
|
|
|