[Include] Random Messages 1.0 Friendly user!
#1

Introduction
Hello, and yes another random messages script!
But this one is easier!
With just 1 function you can add random messages easly in your server!
What's the difference then?
Just go in your script, and do this:
pawn Код:
#include <RandomMessages>
The code is simple:
AddRandomMessage(Msgcolor,Msgtext[])
Go under OnGameModeInit, and for example do this:
pawn Код:
AddRandomMessage(red,"Herro :D");
You can add as many as you want but you just have to change this:
pawn Код:
#define MAX_MESSAGES     50
By default, it's 50 but feel free to add more if you want (:
Aswell the timer delay is 60 seconds aka 1 minute.
You can change it if you want by doing this
pawn Код:
#define MESSAGE_DELAY TIME HERE IN SECONDS!!!
Else it's 1 minute (:
Pictures?

Bugs
None!
Feel free to pm me, or post it here if you find any!

Download
No credits in it (:
5 min job so the credits can go to you if you want :b
Pastebin 2.0: http://pastebin.com/RBLyD5Aj
2.0: Fixed a thing, thanks to the stalking hiddos.
Reply
#2

Nice post, you need to make something extra.. extra unique!!
Reply
#3

Quote:
Originally Posted by MadSkillz
Посмотреть сообщение
Nice post, you need to make something extra.. extra unique!!
Lol any suggestions?
OT:
Thank you :b
Reply
#4

I'd do with loading/saving/removing. Also the size 64 is not enough for some messages.

Edit:
And why :
pawn Код:
#if defined MAX_MESSAGES
#undef MAX_MESSAGES
#define MAX_MESSAGES                    50
#else
#define MAX_MESSAGES                    50
#endif
You should let the users define it before including it.
pawn Код:
#if !defined MAX_MESSAGES
   #define MAX_MESSAGES 50
#endif
Reply
#5

Well done .
Reply
#6

Quote:
Originally Posted by wups
Посмотреть сообщение
I'd do with loading/saving/removing. Also the size 64 is not enough for some messages.

Edit:
And why :
pawn Код:
#if defined MAX_MESSAGES
#undef MAX_MESSAGES
#define MAX_MESSAGES                    50
#else
#define MAX_MESSAGES                    50
#endif
You should let the users define it before including it.
pawn Код:
#if !defined MAX_MESSAGES
   #define MAX_MESSAGES 50
#endif
I was in dought if !define would work :b
Anyways thanks for the tip (:
Quote:
Originally Posted by HyperZ
Посмотреть сообщение
Well done .
Gracias buddy (:
Reply
#7

How about that
AddRandomMessage(COLOUR, Text, AMMOUNT OF TIME Reseting);
Isn't more easy?, other ways nice.
Reply
#8

Quote:
Originally Posted by Naruto_Emilio
Посмотреть сообщение
How about that
AddRandomMessage(COLOUR, Text, AMMOUNT OF TIME Reseting);
Isn't more easy?, other ways nice.
Thanks for the suggestion and I think it's nice too but hard to script.
Otherwise I guess it would have to be a timer for each message
Reply
#9

Awesome work, simple but very nice..

+Rep to u.
Reply
#10

Quote:

Friendly user!

The User are friendly with this Include? JEAH, this is unique. [Irony]

Nice job.
Reply
#11

Quote:
Originally Posted by Pablo Borsellino
View Post

The User are friendly with this Include? JEAH, this is unique. [Irony]

Nice job.
"Random Messages 1.0 Friendly user!"
Do you see Unique writen?
No. Go away.
Reply
#12

Add this for the easily usage!
Code:
native AddRandomMessage(Msgcolor, Msgtext[]);
Reply
#13

Quote:
Originally Posted by TheGamer!
View Post
Add this for the easily usage!
Code:
native AddRandomMessage(Msgcolor, Msgtext[]);
Lol?
Reply
#14

Isn't it User Friendly? wtf u on ? o.o
Reply
#15

Quote:
Originally Posted by Porsche911
View Post
Isn't it User Friendly? wtf u on ? o.o
What?
Reply
#16

Few things:
1. Double the amount of cells for each message.
2. What is this:
Code:
colormsg[12]
. Colours are integer, I don't get it why you're storing it as a string. I'm surprised it compiled without errors.
3. It's 'user friendly', not 'friendly user'.
Reply
#17

Quote:
Originally Posted by Hiddos
View Post
Few things:
1. Double the amount of cells for each message.
2. What is this:
Code:
colormsg[12]
. Colours are integer, I don't get it why you're storing it as a string. I'm surprised it compiled without errors.
3. It's 'user friendly', not 'friendly user'.
I'm sorry, but colors are not integers.
0xFFD2C8FF tell me if that's an integer.
Reply
#18

Quote:
Originally Posted by FireCat
View Post
I'm sorry, but colors are not integers.
0xFFD2C8FF tell me if that's an integer.
It's definitely not a string.
Reply
#19

Quote:
Originally Posted by YJIET
View Post
It's definitely not a string.
He explained me it threw msn :b
Reply
#20

Very Nice You Beat Me To It But Mine Was A Little Different =D
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)