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

Fast Attack with storage

115820

Member
Joined
Feb 27, 2011
Messages
193
Solutions
1
Reaction score
5
Location
London, England
Hi, i have this script but works with SKILL_FIST, and i want change to STORAGE

Code:
uint32_t Player::getAttackSpeed() const
{
    int32_t SpeedAttack;
    SpeedAttack = vocation->getAttackSpeed() - (getSkill(SKILL_FIST, SKILL_LEVEL) * 10);

    if (SpeedAttack < 500) {
        return 500;
    } else {
        return (uint32_t) SpeedAttack;
    }
}
 
Solution
Set your storage ID here:
getStorage(12345, value);

C++:
uint32_t Player::getAttackSpeed() const
{
    int32_t SpeedAttack;

    std::string value;
    getStorage(12345, value);
    int32_t storage_as = atoi(value.c_str());

    SpeedAttack = vocation->getAttackSpeed() - (storage_as * 10);

    if (SpeedAttack < 500) {
        return 500;
    } else {
        return (uint32_t) SpeedAttack;
    }
}
Set your storage ID here:
getStorage(12345, value);

C++:
uint32_t Player::getAttackSpeed() const
{
    int32_t SpeedAttack;

    std::string value;
    getStorage(12345, value);
    int32_t storage_as = atoi(value.c_str());

    SpeedAttack = vocation->getAttackSpeed() - (storage_as * 10);

    if (SpeedAttack < 500) {
        return 500;
    } else {
        return (uint32_t) SpeedAttack;
    }
}
 
Solution
Set your storage ID here:
getStorage(12345, value);

C++:
uint32_t Player::getAttackSpeed() const
{
    int32_t SpeedAttack;

    std::string value;
    getStorage(12345, value);
    int32_t storage_as = atoi(value.c_str());

    SpeedAttack = vocation->getAttackSpeed() - (storage_as * 10);

    if (SpeedAttack < 500) {
        return 500;
    } else {
        return (uint32_t) SpeedAttack;
    }
}
Thanks, i will try!

EDIT

Works so fucking great!


#EDIT
 
Last edited:
Back
Top