• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

[Scripting] Delay or ?

Lording

Well-Known Member
Joined
Jan 9, 2008
Messages
802
Reaction score
80
Hello, I am pretty bad at script's so I would like if you help me in this line

doCreatureSay(cid, "!aol")

Is in login.lua It "Works" but the character doesn't really get the aol just say the command, I think the character need 1 second or something to work.


Any idea?
 
you want !aol
then go talkactions -.-
name it aol.lua
LUA:
function onSay(cid, words, param) 
        if doPlayerRemoveMoney(cid, 20000) == TRUE then 
doPlayerAddItem(cid, 2173, 2) 
                        doSendMagicEffect(getPlayerPosition(cid), 53) 
doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,'You have bought an amulet of loss!!')  
else 
            doPlayerSendCancel(cid, "You need 2 crystal coin to buy a Amulet Of Loss!") 
                end 
return TRUE 
                end

talkactions.xml
XML:
<talkaction words="!aol" script="aol.lua" />
 
I want each time I Loggin, is for war server.

I already got that command but i want to execute every time a character loggin and doesn't work (after a second it works)
 
no delay needed or somthing this will just not work use this function
LUA:
doCreatureExecuteTalkAction(cid, text[, ignoreAccess = false[, channelId = CHANNEL_DEFAULT]])
 
Back
Top