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

TFS 0.X Items/weapons xml trouble

Status
Not open for further replies.

ralke

(҂ ͠❛ ෴ ͡❛)ᕤ
Joined
Dec 17, 2011
Messages
1,512
Solutions
27
Reaction score
865
Location
Santiago - Chile
GitHub
ralke23
Twitch
ralke23
Hi again, i have this issue when adding zaoan items to items.xml (to fix the wrong ids). For example, here I have snake god's wrisguard:
Lua:
<item id="12647" article="a" name="snake god's wristguard">
<attribute key="description" value="It shows your spells and can also shield against attacks when worn." />
<attribute key="weight" value="2800" />
<attribute key="magiclevelpoints" value="3" />
<attribute key="defense" value="14" />
<attribute key="weaponType" value="shield" />
</item>

then I added this code on movements.xml to make the item add atributes, have level requeriement, and vocation restriction.
Lua:
<movevent event="Equip" itemid="12647" slot="shield" level="100" function="onEquipItem">
<vocation id="1" />
<vocation id="5" showInDescription="1" />
<vocation id="2" />
<vocation id="6" showInDescription="1" />
</movevent>
<movevent event="DeEquip" itemid="12647" slot="shield" function="onDeEquipItem"/>

but It doesnt work, player dont get magic level points raised, there's no level restriction, and vocations restriction doesnt work, how i can fix this? The only idea I have is to fix items.otb but there might be other ways to fix this... Even if I have to use a new script it would be fine, please help!! ^^

thanks in advance
 
Solution
solved!! ive just saw i was writing movevent event instead of movevent type rofl
solution:
Lua:
<movevent type="Equip" itemid="12647" slot="shield" level="100" function="onEquipItem">
<vocation id="1" />
<vocation id="5" showInDescription="1" />
<vocation id="2" />
<vocation id="6" showInDescription="1" />
</movevent>
<movevent type="DeEquip" itemid="12647" slot="shield" function="onDeEquipItem"/>
<movevent type="Equip" itemid="12647" slot="shield" level="60" event="function" value="onEquipItem">
<movevent type="DeEquip" itemid="12647" slot="shield" event="function" value="onDeEquipItem"/>
<vocation id="1"/>
<vocation id="5" showInDescription="0"/>
<vocation id="2"/>
<vocation id="6" showInDescription="0"/>
</movevent>

Try this,
 
<movevent type="Equip" itemid="12647" slot="shield" level="60" event="function" value="onEquipItem">
<movevent type="DeEquip" itemid="12647" slot="shield" event="function" value="onDeEquipItem"/>
<vocation id="1"/>
<vocation id="5" showInDescription="0"/>
<vocation id="2"/>
<vocation id="6" showInDescription="0"/>
</movevent>

Try this,

working, thanks a lot!!
edit: it has a trouble, when i take off equipment the skill dont reduce

36262

how can i solve this? thanks in advance
 
solved!! ive just saw i was writing movevent event instead of movevent type rofl
solution:
Lua:
<movevent type="Equip" itemid="12647" slot="shield" level="100" function="onEquipItem">
<vocation id="1" />
<vocation id="5" showInDescription="1" />
<vocation id="2" />
<vocation id="6" showInDescription="1" />
</movevent>
<movevent type="DeEquip" itemid="12647" slot="shield" function="onDeEquipItem"/>
 
Solution
Status
Not open for further replies.
Back
Top