Welcome back! Now I'll show you how to make a color word when he writes the word "noob". Let's get started
First open your talkactions/talkactions.xml
And write this code:
Next open your talkactions/scripts and create file noob.lua
and write this code
Congratulations! You did it. Say word "noob" on your ots.
Tested with TFS 0.3.5 . Dont forget to rep++ me!
Greetings natix4!
First open your talkactions/talkactions.xml
And write this code:
Code:
<talkaction access="0" words="noob" script="noob.lua"/>
and write this code
Screen:local colors =
{
TEXTCOLOR_BLUE,
TEXTCOLOR_LIGHTBLUE,
TEXTCOLOR_LIGHTGREEN,
TEXTCOLOR_TEAL,
TEXTCOLOR_PURPLE,
TEXTCOLOR_PLATINUMBLUE,
TEXTCOLOR_LIGHTGREY,
TEXTCOLOR_DARKRED,
TEXTCOLOR_RED,
TEXTCOLOR_ORANGE,
TEXTCOLOR_YELLOW,
TEXTCOLOR_WHITE_EXP
}
function onSay(cid, words, param)
local playerpos = getPlayerPosition(cid)
local random = math.random(1, #colors)
if math.max(math.abs(playerpos.x-23), math.abs(playerpos.y-30)) < 9999 then
doSendAnimatedText(playerpos, "NOOB!", colors[random])
return 0
end
return 1
end
![12363050.jpg](/proxy.php?image=http%3A%2F%2Fimg402.imageshack.us%2Fimg402%2F6104%2F12363050.jpg&hash=051547cae558a42e6de89217bd3cdd7d)
Congratulations! You did it. Say word "noob" on your ots.
Tested with TFS 0.3.5 . Dont forget to rep++ me!
Greetings natix4!
Last edited: