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

Condition Icon

mackerel

Well-Known Member
Joined
Apr 26, 2017
Messages
398
Solutions
18
Reaction score
74
Hi,

I've noticed you can set icons to be shown when specific condition is executed. For example, haste (utani hur);

you get this;

J2NFAgh.png


I've looked at the haste spell script and didn't find anything useful there, which means it must be inside the source

LUA:
local combat = Combat()
combat:setParameter(COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN)
combat:setParameter(COMBAT_PARAM_AGGRESSIVE, 0)

local condition = Condition(CONDITION_HASTE)
condition:setParameter(CONDITION_PARAM_TICKS, 33000)
condition:setFormula(0.3, -24, 0.3, -24)
combat:setCondition(condition)

function onCastSpell(creature, var)
    return combat:execute(creature, var)
end

If anyone can point me in the right direction that would be cool!

TFS 1.0, if that helps
 
Yeah, its located in this function in sources:
Code:
uint32_t Player::getClientIcons() const

and here:
Code:
uint32_t ConditionSpeed::getIcons() const

The icon is called ICON_HASTE
 
Yeah, its located in this function in sources:
Code:
uint32_t Player::getClientIcons() const

and here:
Code:
uint32_t ConditionSpeed::getIcons() const

The icon is called ICON_HASTE

Do you know which files in source exactly if I wanted to add another condition with icon?
 
Solution
Back
Top