EOSERV Forum > EOSERV > Entering map problem (reborn)
Page: << 1 >>
Entering map problem (reborn)
Author Message
Post #204116 Entering map problem (reborn)

Hello, i've got a problem. I made reborn command on my server, it's working fine, but when i try to enter a map with eg. 0lvl and 1rb i cant get through, level issue. I tried this


if (warp)

{

if ((from->level >= warp.levelreq || from->reborn > 0) && (warp.spec == Map_Warp::NoDoor || warp.open))

{

Map* map = this->world->GetMap(warp.map);

if (from->SourceAccess() < ADMIN_GUIDE && map->evacuate_lock && map->id != from->map->id)

{

from->StatusMsg(this->world->i18n.Format("map_evacuate_block"));

from->Refresh();

}

else

{

from->Warp(warp.map, warp.x, warp.y);

}


return WalkWarped;

}


but it doesn't work. It works on command like this


if(X > 0 && Y > 0 && (character->level >= lvl || character->reborn > 0))

                {

                    if(static_cast<std::string>(character->world->warps_config["WarpsAnimation"]) == "none")

                    {

                        character->Warp(Map, X, Y, WARP_ANIMATION_NONE);

                    }

                    else

                    {

                        character->Warp(Map, X, Y, WARP_ANIMATION_ADMIN);

                    }

                }


Any ideas?

6 years, 1 week ago
Post #204117 Re: Entering map problem (reborn)

maybe just run a quick check

bool can_warp = (from->level >= warp.levelreq  || from->reborn);

if(can_warp)

{

    Console::Out("I can warp. level %i, reborns %i", (int)from->level,(int)from->reborns);

}

else

{

    Console::Out("I can not warp. level %i, reborns %i", (int)from->level,(int)from->reborns);

}


if (can_warp && (warp.spec == Map_Warp::NoDoor || warp.open))

{

6 years, 1 week ago
Post #204118 Re: Entering map problem (reborn)

Still doesn't work if i dont have enoguh lvl

6 years, 1 week ago
Post #204120 Re: Entering map problem (reborn)
deaviss posted: (23rd Apr 2018, 07:27 pm)

Still doesn't work if i dont have enoguh lvl


I am wondering if this might be client sided where the client checks the lvl requirement. I am not sure but your code looks correct to me I'll look arround a bit more and see if I can figure anything out!
6 years, 1 week ago
Post #204121 Re: Entering map problem (reborn)

Ye, i've deleted the code with lvlreq but it still doesn't work. I think it's something with packets

6 years, 1 week ago
Post #204122 Re: Entering map problem (reborn)

LevelReq is client sided although the server enforces it. My problem with reborn is why the level is reset to 0. If you want to shit-hack the level just fudge the top level the client can display for each level up the character has. In other words, lock the character level at 250 as far as sending the client the current player's level, and continue to let exp rack up and let the level up calculation continue in the background - OR - don't treat your server like an action replay hack that quickly dumps exp onto a character to break client limitations.

6 years, 1 week ago
Page: << 1 >>

EOSERV Forum > EOSERV > Entering map problem (reborn)