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

[TFS 1.2] Rune Match event

Also I made the room a bit smaller but it seems that you can't do that without fcking up the script xD there are about 7~8 runes left that are not the same :p I couldn't rlly find out how to change that. It should be changed here right?

Code:
function newBoard()
   cleanBoard()
    table.shuffle(MATCH.SHOWN)
    local i, k, l, x, y = 0, {}, MATCH.SIZE[1]*MATCH.SIZE[2], MATCH.BOARD.from.x, MATCH.BOARD.from.y
    for index = 1, (MATCH.SIZE[1]*MATCH.SIZE[2])/2 do
        table.insert(k, MATCH.SHOWN[index])
        table.insert(k, MATCH.SHOWN[index])
    end
    while i < l do
        v, p = k[math.random(#k)], Position(x, y, MATCH.BOARD.from.z)
        p:sendMagicEffect(10)
        table.remove(k, table.getIndex(k, v))
        r = Item(doCreateItemEx(MATCH.HIDDEN, 1))
        r:setActionId(31337)
        r:setAttribute(ITEM_ATTRIBUTE_CHARGES, v)
        doTileAddItemEx(p, r:getUniqueId())
        i = i + 1
        if x == MATCH.BOARD.to.x then
            y = y + 1   
            x = MATCH.BOARD.from.x
        else
            x = x + 1
        end
    end
end
 
Is there a time limit?
Added now with default 15 min.

Also I made the room a bit smaller but it seems that you can't do that without fcking up the script xD there are about 7~8 runes left that are not the same :p I couldn't rlly find out how to change that.
search and configure (width, height)
Code:
    SIZE = {7, 8},
 
during the game, hide the rune in your backpack, after the match, enter the teleport or travel by ship. 100% crash server;)
 
Back
Top