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

Search results

  1. Mummrik

    Lua Loot/Spawn rate as floating point numbers

    What version of tfs are you using? because in 0.3.6 you can use 1.5 code from monster.cpp uint16_t Monsters::getLootRandom() { return (uint16_t)std::ceil((double)random_range(0, MAX_LOOTCHANCE) / g_config.getDouble(ConfigManager::RATE_LOOT)); } Edit: monster spawn seems to be an integer
  2. Mummrik

    Lua Loot/Spawn rate as floating point numbers

    Did you test it? Edit: Loot rate should be possible i think since its a % value i might be wrong tho not sure about spawn rate I also saw that you did test it. but 1.5 will make an item that has 50% drop rate increas by 25% so the new drop value would be 75% Edit2: i did have a look inside my...
  3. Mummrik

    boss event creature script

    ok great, you can remove that line again. about the bit.band(type, n) this is what i found about it (someone more advanced in Lua might tell you how to use it) lua-users wiki: Bitwise Operators link to quote: https://www.lua.org/manual/5.3/manual.html#3.4.2 so i recommend to remove it for now...
  4. Mummrik

    boss event creature script

    above this line if bit.band(flags, 1) == 1 and isMonster(target) and getCreatureMaster(target) == target and getPlayerStorageValue(cid,config.storage) == 1 then add this print(target) and look in server consol if it prints something
  5. Mummrik

    boss event creature script

    does the player have storage 70200 set to 1? also im not sure what "bit.band(flags, 1) == 1" would do, is that something you set in an other script?
  6. Mummrik

    boss event creature script

    addEvent(f, config.respawnSecs*100) change that to addEvent(f, config.respawnSecs*1000) since 100 would make it 0.1 seconds and 1000 would make it 1 second Edit: local s = getCreatureName(target) if isInArray(t, s:lower()) and getStorage(config.bossspawnstorage) == 0 then That is also...
  7. Mummrik

    How do I write inside a book?

    Ok, try remove the return true from the script since i use a similar script for an other book. and it works great but it did not have the return true. so that must be the reason it wont open the window script should look like this function onUse(cid, item, frompos, item2, topos) if...
  8. Mummrik

    How do I write inside a book?

    Inside your actions folder, then you edit your actions.xml add this to Actions.xml double check if holy tible got itemid 1970, i just took it out of my head so i might be wrong <action itemid="1970" event="script" value="holytible.lua"/>
  9. Mummrik

    How do I write inside a book?

    You can make a Script when someone use/open the book this script is run function onUse(cid, item, frompos, item2, topos) if item.itemid == 1970 then doSetItemText(item.uid, "Banor I praise your name.\nBe with me in the battle.\nBe my shield, let me be your sword.\nI will honor the...
  10. Mummrik

    How it works? (Spells)

    That is what keep the community alive ;)
  11. Mummrik

    How it works? (Spells)

    Should be possible. 1 * 60 * 1000 = 60000 60 * 1000 = 60000 60000 = 60000
  12. Mummrik

    Programmer Looking for programmer

    Inside your database and the player table you have Save, that should be set to 1 on the players you want to be saved, if it is set to 0 it wont save the character.
  13. Mummrik

    Creating functions

    Ok, it seems like you got a script that take care of all the tools in one script. We can take this in private converation, if you want. So let me update your script to take care of the other stuff you wanted aswell. But the items (stone and fir tree) you want to get destoryed need to have...
  14. Mummrik

    Creating functions

    I made 2 scripts that will take care of this but i did also add an actionid (100) to it that you have to set inside mapeditor. If you want every stone or fir tree to get destoryed, you have to remove this code " and itemEx.actionid == 100" from both scripts. then every stone/fir tree is...
  15. Mummrik

    [Lua Function] [0.3.6] doPlayerAddGesiorPoints(cid, points) and doPlayerAddZnotePoints(cid, points)

    Still didnt work, well as i said earlier the position of the player didnt save. I mean i login move the player run the lua function and close the server to replicate a server crash, start it back up and login. The player login at the same posistion it had before i run the lua function. Im not...
  16. Mummrik

    [Lua Function] [0.3.6] doPlayerAddGesiorPoints(cid, points) and doPlayerAddZnotePoints(cid, points)

    Do you know if it exist a function to save a player? something like this doPlayerSave(cid) edit: else something like this should work function doPlayerAddZnotePoints(cid, points) return db.executeQuery("UPDATE znote_accounts SET points = points + "..points.." WHERE account_id =...
  17. Mummrik

    Lua change gold script

    If you didnt update your 000-constant.lua you have to do it. open data/lib/000-constant.lua then search for "ITEM_CRYSTAL_COIN" and below it you have to add this ITEM_GOLD_NUGGET = 2157 -- This itemid might be wrong, check whit your server and change it. ITEM_GOLD_INGOT = 9058 -- This itemid...
  18. Mummrik

    Npc calculate

    Tfs version?
  19. Mummrik

    [Lua Function] [0.3.6] doPlayerAddGesiorPoints(cid, points) and doPlayerAddZnotePoints(cid, points)

    Two Lua functions to add premium points for Znote and Gesior AAC shop Developed for tfs 0.3.6 For Gesior AAC function doPlayerAddGesiorPoints(cid, points) return db.executeQuery("UPDATE accounts SET premium_points = premium_points + "..points.." WHERE id =...
Back
Top