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

Trouble with spell exhaustion

ralke

(҂ ͠❛ ෴ ͡❛)ᕤ
Joined
Dec 17, 2011
Messages
1,492
Solutions
27
Reaction score
858
Location
Santiago - Chile
GitHub
ralke23
Twitch
ralke23
I have some troubles with the exhaustion of my spells, because my players (mostly druids/sorcs) cant cast instant spell and healing spells at the same time, considering that healing spells and instant spells are different kind of spells the exhaust shouldnt be added.

example: when i cast "exevo vis hur" i can't inmediatly cast "exura gran"
other example: when i cast "exevo gran mas frigo" i cant instanly cast "exura sio""

Hope u guys get my point! If u need me to post any file just tell me, thanks in advance!
Using: OTX 2.5
 
Hello boy, what I can tell you is that you configure your spells.xml, example:
Code:
    <instant group="attack" spellid="111" name="Expl" words="pexori" lvl="120" mana="600" prem="1" selftarget="1" cooldown="1000" groupcooldown="1000" needlearn="0" script="attack/se/pexori.lua">

        <vocation name="Slasher" />
        <vocation name="Warrior" />
        <vocation name="Blade" />
    </instant>

If you fit the correct spell group to the two spells everything will be separate
group="
attack""support""healing"
 
Hello boy, what I can tell you is that you configure your spells.xml, example:
Code:
    <instant group="attack" spellid="111" name="Expl" words="pexori" lvl="120" mana="600" prem="1" selftarget="1" cooldown="1000" groupcooldown="1000" needlearn="0" script="attack/se/pexori.lua">

        <vocation name="Slasher" />
        <vocation name="Warrior" />
        <vocation name="Blade" />
    </instant>

If you fit the correct spell group to the two spells everything will be separate
group="
attack""support""healing"

thx for respond, but my .lua file doesnt have instant group on values

here is an example of my exura gran (at spells.xml):

Code:
 <instant name="Intense Healing" words="exura gran" lvl="20" mana="70" aggressive="0" selftarget="1" exhaustion="1000" groups="2,10" icon="2" needlearn="0" event="script" value="healing/intense healing.lua">
        <vocation id="1;5"/>
        <vocation id="2;6"/>
        <vocation id="3;7"/>
    </instant>

recently i realised that this value (maked in red) groups="2,10" change exhaustion time
there's something i can change change on this to make spells work correctly?
 
thx for respond, but my .lua file doesnt have instant group on values

here is an example of my exura gran (at spells.xml):

Code:
 <instant name="Intense Healing" words="exura gran" lvl="20" mana="70" aggressive="0" selftarget="1" exhaustion="1000" groups="2,10" icon="2" needlearn="0" event="script" value="healing/intense healing.lua">
        <vocation id="1;5"/>
        <vocation id="2;6"/>
        <vocation id="3;7"/>
    </instant>

recently i realised that this value (maked in red) groups="2,10" change exhaustion time
there's something i can change change on this to make spells work correctly?

You may have run into a bug with that server type, if your server is the same as in this link(which it looks like it) then you might be better off with a different and more stable distro.

Link mentioned: Lua - spells exhaustion
 
You may have run into a bug with that server type, if your server is the same as in this link(which it looks like it) then you might be better off with a different and more stable distro.

Link mentioned: Lua - spells exhaustion

I saw the post and i got that problem! you should be able to cast attk and heal spell at the same time and that's the error
my distribution has been working perfectly fine for 6 months i dont really want to change it, i prefer to fix the issue related to spells because is the only bug i have :D
 
I saw the post and i got that problem! you should be able to cast attk and heal spell at the same time and that's the error
my distribution has been working perfectly fine for 6 months i dont really want to change it, i prefer to fix the issue related to spells because is the only bug i have :D

It seems to be a source problem to me. But personally I would first try to find out what what spell group id's mean in your server and make sure they are correct on both version then just play around with them and see if you can fix it, maybe try adding just one group id instead of multiple. Just some ideas, wish I could help you more, good luck bro!
 
It seems to be a source problem to me. But personally I would first try to find out what what spell group id's mean in your server and make sure they are correct on both version then just play around with them and see if you can fix it, maybe try adding just one group id instead of multiple. Just some ideas, wish I could help you more, good luck bro!

thxxxx u helped me! any way to verify if my sources are not working correctly? or to deeply access to exhaust configuration
here i have this file 034-exhaustion.lua on folder libs maybe it helps with something

Code:
exhaustion =
{
    check = function (cid, storage)
        if(getPlayerFlagValue(cid, PLAYERFLAG_HASNOEXHAUSTION)) then
            return false
        end

        return getPlayerStorageValue(cid, storage) >= os.time()
    end,

    get = function (cid, storage)
        if(getPlayerFlagValue(cid, PLAYERFLAG_HASNOEXHAUSTION)) then
            return false
        end

        local exhaust = getPlayerStorageValue(cid, storage)
        if(exhaust > 0) then
            local left = exhaust - os.time()
            if(left >= 0) then
                return left
            end
        end

        return false
    end,

    set = function (cid, storage, time)
        setPlayerStorageValue(cid, storage, os.time() + time)
    end,

    make = function (cid, storage, time)
        local exhaust = exhaustion.get(cid, storage)
        if(not exhaust) then
            exhaustion.set(cid, storage, time)
            return true
        end

        return false
    end
}

bump

@Apollos groups are 1 attack 2 healing 3 support i tried changing healing spells to support group and does not work, how can i change exhaustion of groups ??

bump

bump
 
Last edited by a moderator:
Back
Top