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

Script to set level according to vocation

Detallado

New Member
Joined
Jul 25, 2009
Messages
4
Reaction score
0
Hello, I've trying to find a script that sets a player magic level according to his vocation


So, if a player is mage he will set his magic lvl to 70 and if he's knight it will set it to 10 and so on...

Also, a script that when a player clicks on a chest it gives him a backpack with a bunch of items inside
 
Lua:
 local config = {
	magemagic = 70,
	knightmagic = 10
	pallymagic = xx
}

function onLogin(cid)
         if getPlayerStorageValue(cid, 123456) == -1 then
            if getPlayerVocation(cid) == 1 then --Mage
            doPlayerAddMagLevel(cid, config.magemagic)
            elseif getPlayerVocation(cid) == 2 then
            doPlayerAddMagLevel(cid, config.magemagic)

I've started something simple for you. I don't condone just giving away scripts to new people cause most likely you have never tried to work on something like this yourself. So try to finish this. If you need help with particular parts of this you can message me.
 
I've tried, but sadly I don't know much about programming or scripting therefore what I do is that I try to make commands and scripts as simple as possible.

Lua:
 local config = {
	magemagic = 70,
	knightmagic = 10
	pallymagic = xx
}

function onLogin(cid)
         if getPlayerStorageValue(cid, 123456) == -1 then
            if getPlayerVocation(cid) == 1 then --Mage
            doPlayerAddMagLevel(cid, config.magemagic)
            elseif getPlayerVocation(cid) == 2 then
            doPlayerAddMagLevel(cid, config.magemagic)

I've started something simple for you. I don't condone just giving away scripts to new people cause most likely you have never tried to work on something like this yourself. So try to finish this. If you need help with particular parts of this you can message me.
 
Back
Top