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

HELP! Minimum Level for War server

noco2171

New Member
Joined
May 9, 2012
Messages
4
Reaction score
0
Is there any scripts or any settings to make players not go below a certain level?

For example: I have made a war OT where the starting level is 50. but when i die i drop to level 49. is there any way to set the minimum level to 50?

Also, is there any scripts to make players never loose equipment and bp, and how to make a admin account.

thanks
 
U can MAke a "Forever aol" for lal players.
For Admin Account u shoud go to "datas of server-Players" add to your Account ID/group 5-6
If u wana open account manage try pass.: 1 / acc.: 1 or just press "Enter"
 
You can make the charges like 10000, its about the same as a forever aol, because people probable won't die that often.

For the minimum lvl script you can do it like this.

Creaturescripts.xml
XML:
<event type="think" name="LevelUp" event="script" value="setlevel.lua"/>

setlevel.lua
Lua:
function onThink(cid, interval)
	if(getPlayerLevel(cid) < 50) then
	local name = getCreatureName(cid)
	doRemoveCreature(cid)
	db.executeQuery("UPDATE players SET level = 50 WHERE name ='"..name.."';")
end
return TRUE
end
Add this line in login.lua (above return true)
Lua:
registerCreatureEvent(cid, "LevelUp")

If you think the relog is annoying, you can also use: doPlayerAddLevel(cid, 1)
But this won't make it exactly at the start of level 50.
 
thank you so much haha, it worked.

Do you know how to create an admin character now? im not really sure because when i try to change the group id it wont go past 3
 
You can't change the group id to 6 in your database? If not, go to data, XML, groups.xml and look if everything is in there.
 
I did, and everything is there,

I also have a few other requests if you dont mind, including the xml code and everything please, haha:)

1. Starting skills(cant have everyone starting with 0 skills)
2. Starting with a bag on at least, so you can open the chests(im using tfs 0.3.6 and i know its bugged, but even when i made the chests to open for eq, it says "21:29 You have found a reward weighing 255.7 oz. It is too heavy or you have not enough space." Even if i have enough cap, and no bag in my slot. The item is a bp with all the needed items inside.
3. A script so you when you kill anybody, you get 5 plats

PS: i fixed the aol thing, and the minimum level:)
 
1. You can try this. (add this the same way as the minimum lvl script, with other name ofc and type login)
Lua:
function onLogin(cid)
local playerVoc = getPlayerVocation(cid)
local reqTries = getPlayerRequiredSkillTries
local skillStor = 56364
local gotSkills = getPlayerStorageValue(cid, 56364)
 
 
if playerVoc == 5 and gotSkills == -1 then
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,20)))
setPlayerStorageValue(cid, skillStor, 1)
 
elseif playerVoc == 6 and gotSkills == -1 then
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,20)))
setPlayerStorageValue(cid, skillStor, 1)
 
elseif playerVoc == 7 and gotSkills == -1 then
doPlayerAddSkillTry(cid, SKILL_DISTANCE, reqTries(cid, SKILL_DISTANCE, 20))
doPlayerAddSkillTry(cid, SKILL_SHIELD, reqTries(cid, SKILL_SHIELD, 20))
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,10)))
setPlayerStorageValue(cid, skillStor, 1)
 
elseif playerVoc == 8 and gotSkills == -1 then
doPlayerAddSkillTry(cid, SKILL_AXE, reqTries(cid, SKILL_AXE, 20))
doPlayerAddSkillTry(cid, SKILL_SWORD, reqTries(cid, SKILL_SWORD, 20))
doPlayerAddSkillTry(cid, SKILL_CLUB, reqTries(cid, SKILL_CLUB, 20))
doPlayerAddSkillTry(cid, SKILL_SHIELD, reqTries(cid, SKILL_SHIELD, 20))
doPlayerAddMagLevel(cid, 8)
setPlayerStorageValue(cid, skillStor, 1)
 
end
return TRUE
end

2. Then you really need to get an other distro unless you know how to compile.

3. Try this, (also same way as the minimun lvl script with type kill)
Lua:
function onKill(cid, target, lastHit)

	if isPlayer(cid) and isPlayer(target) then
			doPlayerAddItem(cid, 2152, 5)
	end
	return TRUE
end

If it doesn't work I will test them and see if I can make them work.
 
Last edited:
Does the plats for frags thing only give plats if you get the final hit?
I had already tried the skill one but it didnt seem to work for me
And i dont have a clue how to compile, so im out of luck for the starter items?
 
I suggest to just download on other server, it seems that 1 server has this problem (everyone who got this problem downloaded the same server), so by using an other one will probable solve it.
I can make a startskill script tomorrow, but it will take some time.

Btw, if you have them, you can also edit the samples in database.
 
Last edited:
i had worded that wrong, i meant i dont want to go below x level. But its solved now, thanks though

Does anybody know what skills are good to start at for a war server? you start at level 50
 
Last edited:
Oh the kill script I made works for other people who helped too, just tested it :p

Will work now on the startskills script.
 
And also one more thing, sorry for asking for all of this,
Is there a way i can make it equip the BP i get from the chest? or is that still the same problem with the server
 
Ye, that's the same thing, all additem functions doesn't work in your server.

But here is the firstskills script.
Lua:
function onThink(cid, interval)

local queststatus = getPlayerStorageValue(cid,9500)
local playerVoc = getPlayerVocation(cid)

	if playerVoc == 1 and queststatus == -1 then
	doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,30)))
	setPlayerStorageValue(cid, 9500, 1)
	end

	if playerVoc == 2 and queststatus == -1 then
	doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,30)))
	setPlayerStorageValue(cid, 9500, 1)
	end

	if playerVoc == 3 and queststatus == -1 then
	doPlayerAddSkillTry(cid, SKILL_DISTANCE, 20)
	doPlayerAddSkillTry(cid, SKILL_SHIELD, 20)
	doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,10)))
	setPlayerStorageValue(cid, 9500, 1)
	end

	if playerVoc == 4 and queststatus == -1 then
	doPlayerAddSkillTry(cid, SKILL_AXE, 20)
	doPlayerAddSkillTry(cid, SKILL_SWORD, 20)
	doPlayerAddSkillTry(cid, SKILL_CLUB, 20)
	doPlayerAddSkillTry(cid, SKILL_SHIELD, 20)
	doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,4)))
	setPlayerStorageValue(cid, 9500, 1)

end
return TRUE
end
 
alright it works, and thank you, but when i type in skill i want it to be, its a little bit off, like when you had for player voc 3, required mana for ml 10 it gave me like 12.6 or smthn

When i try to put 60 skills for knights
and 70/50 skills for pallys
and 45ml mages
its the same thing, im guessing theres something obvious im doing wrong? haha
 
Last edited:
Back
Top