Topic is locked.
Page: << 1 2 >>
AoE
Author Message
Post #60009 Re: AoE

I think one of the aoe codes i seen on the forum he used rbuilder in


Map::Walk(Character*, Direction, bool)':
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: expected ';' before 'rbuilder'
14 years, 33 weeks ago
Post #60010 Re: AoE
insomniac posted: (28th Jan 2011 06:07 pm)

I think one of the aoe codes i seen on the forum he used rbuilder in


Map::Walk(Character*, Direction, bool)':
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: expected ';' before 'rbuilder'

But my quest.hpp doesnt even have 1000 lines in it only 65
14 years, 33 weeks ago
Post #60011 Re: AoE

Im not sure why it does that your quest.hpp is fine the problem is in bool Map::Walk




Compiling: ..\src\map.cpp               <---- shows what it was compiling when errors happened

then below shows what function in map.cpp that the errors were in

v1.1b2\src\quest.hpp: In member function 'bool Map::Walk(Character*, Direction, bool)':


C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: expected ';' before 'rbuilder'

the quest thing usualy happens when compiling Im not sure why but has nothing to do with problem!

I would just undo to before you started adding the aoe!



14 years, 33 weeks ago
Post #60013 Re: AoE
insomniac posted: (28th Jan 2011 06:20 pm)

Im not sure why it does that your quest.hpp is fine the problem is in bool Map::Walk




Compiling: ..\src\map.cpp               <---- shows what it was compiling when errors happened

then below shows what function in map.cpp that the errors were in

v1.1b2\src\quest.hpp: In member function 'bool Map::Walk(Character*, Direction, bool)':


C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: expected ';' before 'rbuilder'

the quest thing usualy happens when compiling Im not sure why but has nothing to do with problem!

I would just undo to before you started adding the aoe!



Okay ill try

14 years, 33 weeks ago
Post #60015 Re: AoE

If you feel like it you can post your map.cpp in a pastebin and ill fix/add the aoe in

14 years, 33 weeks ago
Post #60017 Re: AoE
insomniac posted: (28th Jan 2011 06:24 pm)

If you feel like it you can post your map.cpp in a pastebin and ill fix/add the aoe in


Alright heres the link of my map.cpp
14 years, 33 weeks ago
Post #60018 Re: AoE

Alrighty Im on it brb!

14 years, 33 weeks ago
Post #60020 Re: AoE

Off topic: Oh well, I'm really sick. My eyes hurt. So I'm really tired xD


On topic: So I'll be back tomorrow to see if you have fixed it I really apprechiate you're help =)

Just note my errors was theese :D



-------------- Build: MYSQL+SQLITE in eoserv ---------------

Compiling: ..\src\map.cpp
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp: In member function 'bool Map::Walk(Character*, Direction, bool)':
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: expected ';' before 'rbuilder'
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1051: error: statement cannot resolve address of overloaded function
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp: In member function 'void Map::Attack(Character*, Direction)':
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1403: error: 'npc' was not declared in this scope
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp: At global scope:
C:\Users\Matias\Desktop\Spil\Endless-Online\EOSERV LEWIS FIX!!!!\Lewis999's Rev189 v1.1b2\src\quest.hpp:1491: error: expected declaration before '}' token
Process terminated with status 1 (0 minutes, 0 seconds)
4 errors, 0 warnings
 

14 years, 33 weeks ago
Post #60022 Re: AoE

try and replace the map.cpp with this 1 i think its fixed and aoe added


here ya go

14 years, 33 weeks ago
Post #60076 Re: AoE
insomniac posted: (28th Jan 2011 06:49 pm)

try and replace the map.cpp with this 1 i think its fixed and aoe added


here ya go


Weird thanks it worked.. I'm just gonna replace Austins code in it again :P
EDIT: Wait did you just delete the code Map::Attack? Cause I cant find it o.O


EDIT2: Nvm, I found it but Im still having problems?


EDIT3: Oh and Austin just to let you know, I am not sure if you're code works properly because I did put the distance on 2 but ingame the distance is like 20? I can hit ---> that way and it hits monster 20 tiles away behind me WTF?
14 years, 33 weeks ago
Post #60107 Re: AoE

Then you edited it wrong, because it works just fine. It attacks in a 4x4 square around me, so i don't know about you.

---
Create your own destiny, don't let someone else do it for you.
14 years, 33 weeks ago
Post #60109 Re: AoE
AustinB posted: (29th Jan 2011 10:14 am)

Then you edited it wrong, because it works just fine. It attacks in a 4x4 square around me, so i don't know about you.


void Map::Attack(Character *from, Direction direction)
{
PacketBuilder builder;

from->direction = direction;

if (from->arena)
{
from->arena->Attack(from, direction);
}

if (this->pk || (this->world->config["GlobalPK"] && !this->world->PKExcept(this->id)))
{
if (this->AttackPK(from, direction))
{
return;
}
}

builder.SetID(PACKET_ATTACK, PACKET_PLAYER);
builder.AddShort(from->player->id);
builder.AddChar(direction);

UTIL_PTR_LIST_FOREACH(this->characters, Character, character)
{
if (*character == from || !from->InRange(*character))
{
continue;void Map::Attack(Character *from, Direction direction)
{
PacketBuilder builder;

from->direction = direction;

if (from->arena)
{
from->arena->Attack(from, direction);
}

if (this->pk || (this->world->config["GlobalPK"] && !this->world->PKExcept(this->id)))
{
if (this->AttackPK(from, direction))
{
return;
}
}

builder.SetID(PACKET_ATTACK, PACKET_PLAYER);
builder.AddShort(from->player->id);
builder.AddChar(direction);

UTIL_PTR_LIST_FOREACH(this->characters, Character, character)
{
if (*character == from || !from->InRange(*character))
{
continue;
}

character->player->client->SendBuilder(builder);
}

int target_x = from->x;
int target_y = from->y;

int range = 1;

if (this->world->eif->Get(from->paperdoll[Character::Weapon])->subtype == EIF::Ranged)
{
range = static_cast<int>(this->world->config["RangedDistance"]);
}

for (int i = 0; i < range; ++i)
{
switch (from->direction)
{
case DIRECTION_UP:
target_y -= 1;
break;

case DIRECTION_RIGHT:
target_x += 1;
break;

case DIRECTION_DOWN:
target_y += 1;
break;

case DIRECTION_LEFT:
target_x -= 1;
break;
}

if(from->paperdoll[Character::Weapon] == 486)
        {
UTIL_PTR_VECTOR_FOREACH(this->npcs, NPC, closeby)
            {
            int distance = util::path_length(target_x, target_y, closeby->x, closeby->y);
            int amount = util::rand(from->mindam + 0, from->maxdam + 0);

            if (distance <=2 && closeby->alive)
                {
                closeby->Damage(from, amount);
                }
            }
        }

Rite?
14 years, 33 weeks ago
Post #60110 Re: AoE

Yes. That should only attack around you. Are you sure there isn't another person attacking?

Also! There's no way that it kills them 20 tiles back, and you saw it, because the max amount of tiles you can see in the client is 12, Thank you very much ;P

---
Create your own destiny, don't let someone else do it for you.
14 years, 33 weeks ago
Post #60113 Re: AoE
AustinB posted: (29th Jan 2011 10:25 am)

Yes. That should only attack around you. Are you sure there isn't another person attacking?

Also! There's no way that it kills them 20 tiles back, and you saw it, because the max amount of tiles you can see in the client is 12, Thank you very much ;P


But i can see the drops right after i killed them^^ And yes i am sure.. I will make a video and upload it here.

Heres the video

Oh and put the video on HD + Fullscreen or u cant see shit
14 years, 33 weeks ago
Page: << 1 2 >>
Topic is locked.