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

Request Some Lua Scripts

Hrsha

Member
Joined
May 30, 2010
Messages
450
Reaction score
21
Location
Egypt
Hello otlanders

1- spell script when i caste it dmg of my weapon get stronger something like + 20% dmage. and ends after 60 sec

2- i want Spell script ( with x% double hit chance )

3- critical system lua script or source code? that give effect with weapons , wands , rods , spells ?

4- Reflect Dmage spell that ends after 2 minutes

5- explaining of these numbers and difference between setAttackFormula and setCombatFormula

Code:
setAttackFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 1.4, 2.8, 40, 70)
setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, 0, -1, -10, 5, 5, 1.2, 2, -20, -40)
setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, -2, -20, -40)

Thanks for reading
 
1- spell script when i caste it dmg of my weapon get stronger something like + 20% dmage. and ends after 60 sec
what u think about "if you cast this spell your melee fighting skill is increased by 20% for 60 sec."?
Lua:
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, 60 * 1000)
setConditionParam(condition, CONDITION_PARAM_SKILL_MELEEPERCENT, 120)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)

function onCastSpell(cid, var)
	return doCombat(cid, combat, var)
end


2- i want Spell script ( with x% double hit chance )
3- critical system lua script or source code? that give effect with weapons , wands , rods , spells ?
check it, might help you very much
http://otland.net/f82/advanced-rapi...ge-seven-arrows-diablo-amazons-strafe-144932/


4- Reflect Dmage spell that ends after 2 minutes
copy it to your google
Code:
inurl:"otland.net" reflect


5- explaining of these numbers and difference between setAttackFormula and setCombatFormula
only the 3rd works in TFS, rest are from older versions
and these numbers means
Lua:
setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, MINmultipiler, MINcorrector, MAXmultipiler, MAXcorrector)
min damage = (level*1 + level*4) * MINmultipiler - MINcorrector
max damage = (level*1 + level*4) * MAXmultipiler - MAXcorrector

for example player with level 100 and magic level 100
Lua:
setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, -2, -20, -40)
min dmg = (100*1 + 100*4) * (-1) - (-2) = -498
max dmg = (100*1 + 100*4) * (-20) - (-40) = -9960

if you remove "-" from numbers the spell will healing instead of dealing dmg


that is not what i want
i want something to use it on item like this line

<attribute key="criticalhitchance" value="15" />

sources edit only.
 
Back
Top