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

Stupid doubts regarding otserver creation

Suycartep

New Member
Joined
Feb 11, 2020
Messages
1
Reaction score
0
Hey guys, so I recently downloaded the TFS because I am trying to create an otserver 8.60. I have a few doubts on how to change stuff that I want.

1 - How and where do I change the skills and magic level a new player starts with
2 - I changed the starting level to 85 and since it is gonna be a WAR server with personal characters, how can I make a player do not downgrade to level 84 or less.
3 - How can I change the world type to PVP enforced or to a world type that gives you exp when you kill other players.
4 - Is it hard to make a script that whenever you kill a player you get an item (such as a gold coin) that instantly goes into your backpack or anywhere available on your inventory.
5 - Where and how can I change the items a new character starts with
 
1. If you use gesiorAcc, it creates some samples, modify them in ur db so new character will copy his attributes.
2.Try to find function script "player get level" or something. I used it from here.
Code:
function onLogin(cid)
    if(getPlayerLevel(cid) < 85) then
        local setPlayerLevelOnLogin = 85
        doPlayerAddExperience(cid, (getExperienceForLevel(setPlayerLevelOnLogin) - getPlayerExperience(cid)))
    else
        doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Go kill someone!")
    end
    return TRUE
end
3.In ur config.lua change PVP to PVPE or PVP-E
It depends, just try both and check ur console.
4.In data/creaturescript make a function in reward.lua(create it) and make getItem fucntion.
Code:
function onDeath(cid, corpse, deathList)
local reward = {
item = 2152, --Item Id what u give to fragger
count = 1
}
for i = 1, #deathList do
if isPlayer(cid) and isPlayer(deathList[i]) then
if getPlayerIp(cid) ~= getPlayerIp(deathList[i]) then
if getPlayerItemCount(deathList[i], reward.item) > 0 then
local item = getPlayerItemById(deathList[i], true, reward.item)
if item.type >= ITEMCOUNT_MAX then
doPlayerAddItem(deathList[i], reward.item, reward.count)
doCreatureSetStorage(deathList[i], 20233, getPlayerStorageValue(deathList[i], 20233)+1)
doSendAnimatedText(getPlayerPosition(deathList[i]), "Frag!", TEXTCOLOR_RED)
else
doTransformItem(item.uid, reward.item, item.type + 1)
doCreatureSetStorage(deathList[i], 20233, getPlayerStorageValue(deathList[i], 20233)+1)
doSendAnimatedText(getPlayerPosition(deathList[i]), "Frag!", TEXTCOLOR_RED)
end
else
doPlayerAddItem(deathList[i], reward.item, reward.count)
doCreatureSetStorage(deathList[i], 20233, getPlayerStorageValue(deathList[i], 20233)+1)
doSendAnimatedText(getPlayerPosition(deathList[i]), "Frag!", TEXTCOLOR_RED)
end
else
doPlayerAddLevel(deathList[i], -1)
end
end
end
return true
end
5. Find here "exchange NPC".
 
Last edited:
You can use this as a place to start if you like:
This was done for TFS v1.2 client 10.77 however you can probably use TFS 1.3 downgraded to 8.6 by Nekiro with this datapack without too many changes. ([8.60] Latest forgottenserver 1.3. Clean downport. (https://otland.net/threads/8-60-latest-forgottenserver-1-3-clean-downport.263472/page-5#post-2590646))

This datapack already has all the configuration and scripts you are looking for.
 

Similar threads

Back
Top