• 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 make my axe give dist exp.

Lady Donna

New Member
Joined
Aug 14, 2011
Messages
19
Reaction score
0
I have this script, it work spretty good with some obvious downfalls.

If you dont have exp to lose, it puts you into negative (making it look like you gained a ton of levels), and it gives exp in distance every single hit, rather than as normal training. Is there any way to script this to work.. 'correctly'? Im using The Forgotten Server - Version 0.2.11pl2 (Mystic Spirit).

Code:
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1)
setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1)
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
setCombatParam(combat, COMBAT_PARAM_EFFECT, 255)
setCombatFormula(combat, COMBAT_FORMULA_SKILL, 1, 0, 1, 0)

local area = createCombatArea( { {0, 1, 0}, {0, 3, 0}, {0, 0, 0} } )
setCombatArea(combat, area)

function onUseWeapon(cid, var)
	local ret = doCombat(cid, combat, var)
	if(ret == LUA_ERROR) then
		return LUA_ERROR
	end
	if(doPlayerAddSkillTry(cid, SKILL_AXE, 1)) then
		doPlayerAddSkillTry(cid, SKILL_AXE, -1)
		doPlayerAddSkillTry(cid, SKILL_DISTANCE, 1)
	end
end

Also, I have the particular axe weapon still set to axe, since setting it to distance does absolutely nothing -_-
 
Last edited:
Why was this moved to requests, im asking for help with my script, though the title is misleading, can you move it back? Thanks.

Also title change for comfort.
 
Back
Top