• 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!

[REQUEST] Elemental talk

cbrm

Retired scripter
Staff member
Global Moderator
Joined
Jan 6, 2009
Messages
6,599
Solutions
3
Reaction score
972
Location
Caribbean Sea
Well, what I need is a colored popup message(animated text) when certain spell is casted. I don't matter if it can be included in a spell or to make a new talkaction:

LUA:
local pos = getPlayerPosition(cid)

function onSay(cid, words, param)
	if getInstantSpellWords(exevo flam hur) == TRUE then
			doSendAnimatedText(pos, "KATON!", TEXTCOLOR_RED)
        end
        return TRUE
end
that was my talkaction attempt but I just need the animated text
anyone? rep+?:thumbup:

KATON! SUITON! DOTON! RAITON! FUUTON! MOKUTON! HYOUTON!
 
Last edited:
LUA:
function onSay(cid, words, param)
		if words == exevo flam hur then
			getPlayerLearnedInstantSpell(cid, "Fire Wave")
			doSendAnimatedText((getCreaturePosition(cid)), "KATON!", TEXTCOLOR_RED)
		elseif words == exevo vis hur then
			getPlayerLearnedInstantSpell(cid, "Energy Wave")
			doSendAnimatedText((getCreaturePosition(cid)), "BLAH!", TEXTCOLOR_RED)
		end
return true
end
 
Aff, I was sure that I won't be the only one with this forever :D

change in all your spells
Code:
function onCastSpell(cid, var)
	return doCombat(cid, combat, var)
end
to
Code:
function onCastSpell(cid, var)
doSendAnimatedText(getPlayerPosition(cid),"DOTON",TEXTCOLOR_GREEN)
	return doCombat(cid, combat, var)
end

and in custom spells

Just add this line before addEvents
 
Back
Top