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

Cast a spell while standing by the stairs

Solution
I guess you're using the latest TFS since you don't specify it.

In
C++:
ReturnValue Combat::canDoCombat(Creature* caster, Tile* tile, bool aggressive)
Remove
C++:
    if (tile->hasFlag(TILESTATE_FLOORCHANGE)) {
        return RETURNVALUE_NOTENOUGHROOM;
    }
I guess you're using the latest TFS since you don't specify it.

In
C++:
ReturnValue Combat::canDoCombat(Creature* caster, Tile* tile, bool aggressive)
Remove
C++:
    if (tile->hasFlag(TILESTATE_FLOORCHANGE)) {
        return RETURNVALUE_NOTENOUGHROOM;
    }
 
Solution
When I come to think of it, what on earth happens if you shoot a magic wall or a firebomb on a stair? Does the field take the stairs?

If that is the case, I'm not fully sure on how to make a proper solution for you, maybe this could work

In:
C++:
ReturnValue Game::internalAddItem(Cylinder* toCylinder, Item* item, int32_t index,
                                  uint32_t flags, bool test, uint32_t& remainderCount)

Under:
C++:
    if (!toCylinder || !item) {
        return RETURNVALUE_NOTPOSSIBLE;
    }

Add:
C++:
Tile* tile = toCylinder->getTile();
if (tile && tile->hasFlag(TILESTATE_FLOORCHANGE) && item->isMagicField()) {
    return RETURNVALUE_NOTPOSSIBLE;
}

But again - not sure if this is the best approach to your potential problem.
 
Last edited:
@up fuck, didnt notice your edit
however, it would be neat to block the possibility to throw it too, I think

In
C++:
ReturnValue RuneSpell::canExecuteAction(const Player* player, const Position& to
add
C++:
Tile* targetTile = g_game.map.getTile(toPos);
 if (!targetTile || targetTile->hasFlag(TILESTATE_BLOCKSOLID) || targetTile->hasFlag(TILESTATE_FLOORCHANGE)) {
       return RETURNVALUE_NOTENOUGHROOM;
}

That would be <10 Tibia behavior, not sure how it behaves in newer
 
Last edited:
That seems like a better solution all together.
Although both changes are required, otherwise you will be able to create fire fields on other floors shooting fire bombs around the stairs.
 
Last edited:
When I come to think of it, what on earth happens if you shoot a magic wall or a firebomb on a stair? Does the field take the stairs?
7.7: fields is only created around the floorchange tile, but you can still see the distance effect from shooting the rune
 
Emil seem to be correct about 7.7, you can shoot AOE (GFB and w/e) on stairs. When using a field rune like magic wall only the shoot effect is visible and the magic wall is not created. This might have changed in newer versions of Tibia but only god knows when.
 
Emil seem to be correct about 7.7, you can shoot AOE (GFB and w/e) on stairs. When using a field rune like magic wall only the shoot effect is visible and the magic wall is not created. This might have changed in newer versions of Tibia but only god knows when.
That's correct, the Magic wall is not created, and the charge of the rune is not removed. You have any Idea How to not remove the charge of the rune?
 
Just tested in No-Pvp worlds, and in Open PVP worlds, the shoot effect is visible, but a message says: not enough room, and the charge is not removed., when throwing a magic wall.
7.7: fields is only created around the floorchange tile, but you can still see the distance effect from shooting the rune
 
Back
Top