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

C++ decrease speed on equiped items (slots)

Zell

Intermediate OT User
Joined
Oct 23, 2010
Messages
214
Reaction score
117
Hi there! for fun sometimes I try to make some changes to an old otserv that i have, is an old avesta 7.6 SVN 6.3?
I want add a few lines to check when a player equip any item, but i can't find exactly the lines about it.

i mean, when the server reads he puts the armor on slot armor and then i'll make something like.. setspeed(getplayerbasespeed)-item->getWeight/4
and when remove the item again, returns hes basespeed.

I know that can be done on movements but i'll need make a script for every item..right? or can be done just on 1 script to check this?

Can anyone help me to find these on c++ or throw me some light about the movement way?

Thank you!
 
Hi there! for fun sometimes I try to make some changes to an old otserv that i have, is an old avesta 7.6 SVN 6.3?
I want add a few lines to check when a player equip any item, but i can't find exactly the lines about it.

i mean, when the server reads he puts the armor on slot armor and then i'll make something like.. setspeed(getplayerbasespeed)-item->getWeight/4
and when remove the item again, returns hes basespeed.

I know that can be done on movements but i'll need make a script for every item..right? or can be done just on 1 script to check this?

Can anyone help me to find these on c++ or throw me some light about the movement way?

Thank you!


u want decrease speed?

I think I'm sure that if you use the value negatively it should work, or at least that's how the logic seems to work in version 0.6.5, I don't know if it makes much difference.


<attribute key="speed" value="-10" />

 
u want decrease speed?

I think I'm sure that if you use the value negatively it should work, or at least that's how the logic seems to work in version 0.6.5, I don't know if it makes much difference.


<attribute key="speed" value="-10" />

yeah i know the attribute, it can be done on items.xml changing that but i'll need change all the items, and i want make it on sources as shortcut.

on the lines you put there on game.cpp just talks about the change speed, but there is no any line about equipment..i find something on queryadd function but..there is not the way.

thanks!
 
Back
Top