Exedion
Active Member
- Joined
- Jun 11, 2007
- Messages
- 628
- Reaction score
- 30
Well i coming again with my shorts but usefulls scripts for make more "rpg's" the otservers ^^ this time i release a simple and easy underwater system for TheforgottenServer
Here we go:
Make a lua file in moveevents named drown.lua and put this code inside:
and in the movements.xml, put this:
now go to items.xml and search the "helmet of the deep" and put this tag attribute:
and the should be:
Credits to:
Ispiro: give me the script
Heliton: for make the patron script
Exedion : modify ^^
If anyone help this thread making a moveevent that check the player with the helmet, if the player have the helmet, can walk, but if no have, the player walkback... i will give credits and rep... Have fun! Exera Team ^^
PS: Sorry for my bad english...
NOBODY CONGRATULATE??? -.-
Here we go:
Make a lua file in moveevents named drown.lua and put this code inside:
Code:
local drowning = createConditionObject(CONDITION_DROWN)
addDamageCondition(drowning, 6, 2000, -50)
function onStepIn(cid, item, pos)
if isPlayer(cid) ~= FALSE then
doTargetCombatCondition(0, cid, drowning, CONST_ME_NONE)
end
return TRUE
end
and in the movements.xml, put this:
Code:
<!-- Underwater System by Exedion -->
<movevent event="StepIn" itemid="5405" script="drown.lua"/>
<movevent event="StepIn" itemid="5406" script="drown.lua"/>
<movevent event="StepIn" itemid="5407" script="drown.lua"/>
<movevent event="StepIn" itemid="5408" script="drown.lua"/>
<movevent event="StepIn" itemid="5409" script="drown.lua"/>
<movevent event="StepIn" itemid="5410" script="drown.lua"/>
<movevent event="StepIn" itemid="5427" script="drown.lua"/>
<movevent event="StepIn" itemid="5428" script="drown.lua"/>
<movevent event="StepIn" itemid="5429" script="drown.lua"/>
<movevent event="StepIn" itemid="5430" script="drown.lua"/>
<movevent event="StepIn" itemid="5431" script="drown.lua"/>
<movevent event="StepIn" itemid="5432" script="drown.lua"/>
<movevent event="StepIn" itemid="5433" script="drown.lua"/>
<movevent event="StepIn" itemid="5434" script="drown.lua"/>
<movevent event="StepIn" itemid="5435" script="drown.lua"/>
<movevent event="StepIn" itemid="5436" script="drown.lua"/>
<movevent event="StepIn" itemid="5437" script="drown.lua"/>
<movevent event="StepIn" itemid="5438" script="drown.lua"/>
<movevent event="StepIn" itemid="5743" script="drown.lua"/>
<movevent event="StepIn" itemid="5744" script="drown.lua"/>
<movevent event="StepIn" itemid="5763" script="drown.lua"/>
<movevent event="StepIn" itemid="5764" script="drown.lua"/>
now go to items.xml and search the "helmet of the deep" and put this tag attribute:
Code:
<attribute key="suppressDrown" value="1"/>
and the should be:
Code:
<item id="5461" article="a" name="helmet of the deep">
<attribute key="weight" value="21000"/>
<attribute key="armor" value="2"/>
<attribute key="slotType" value="head"/>
<attribute key="suppressDrown" value="1"/>
</item>
Credits to:
Ispiro: give me the script
Heliton: for make the patron script
Exedion : modify ^^
If anyone help this thread making a moveevent that check the player with the helmet, if the player have the helmet, can walk, but if no have, the player walkback... i will give credits and rep... Have fun! Exera Team ^^
PS: Sorry for my bad english...
NOBODY CONGRATULATE??? -.-
Last edited: