diff options
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/map.c | 2 | ||||
-rw-r--r-- | src/map/map.h | 8 | ||||
-rw-r--r-- | src/map/mob.c | 2 | ||||
-rw-r--r-- | src/map/mob.h | 2 | ||||
-rw-r--r-- | src/map/npc.c | 2 |
5 files changed, 8 insertions, 8 deletions
diff --git a/src/map/map.c b/src/map/map.c index 762cf1446..c086b73c0 100644 --- a/src/map/map.c +++ b/src/map/map.c @@ -1509,7 +1509,7 @@ void map_addiddb(struct block_list *bl) TBL_MOB* md = (TBL_MOB*)bl; idb_put(mobid_db,bl->id,bl); - if( md->boss ) + if( md->state.boss ) idb_put(bossid_db, bl->id, bl); } diff --git a/src/map/map.h b/src/map/map.h index 3241efea1..f1e7e49b3 100644 --- a/src/map/map.h +++ b/src/map/map.h @@ -259,16 +259,16 @@ struct block_list { // Expanded to specify all mob-related spawn data by [Skotlex] struct spawn_data { short class_; //Class, used because a mob can change it's class - unsigned boss : 1; unsigned short m,x,y; //Spawn information (map, point, spawn-area around point) signed short xs,ys; unsigned short num; //Number of mobs using this structure unsigned short active; //Number of mobs that are already spawned (for mob_remove_damaged: no) unsigned int delay1,delay2; //Min delay before respawning after spawn/death struct { - unsigned size :2; //Holds if mob has to be tiny/large - unsigned ai :2; //Holds if mob is special ai. - unsigned dynamic :1; //Whether this data is indexed by a map's dynamic mob list + unsigned int size :2; //Holds if mob has to be tiny/large + unsigned int ai :2; //Holds if mob is special ai. + unsigned int dynamic :1; //Whether this data is indexed by a map's dynamic mob list + unsigned int boss : 1; } state; char name[NAME_LENGTH],eventname[EVENT_NAME_LENGTH]; //Name/event }; diff --git a/src/map/mob.c b/src/map/mob.c index 0a99b83b1..4c8fa685a 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -216,7 +216,7 @@ struct mob_data* mob_spawn_dataset(struct spawn_data *data) md->bl.x = data->x; md->bl.y = data->y; md->class_ = data->class_; - md->boss = data->boss; + md->state.boss = data->state.boss; md->db = mob_db(md->class_); memcpy(md->name, data->name, NAME_LENGTH); if (data->state.ai) diff --git a/src/map/mob.h b/src/map/mob.h index 6658c96d3..605439f12 100644 --- a/src/map/mob.h +++ b/src/map/mob.h @@ -128,6 +128,7 @@ struct mob_data { unsigned int spotted: 1; unsigned int npc_killmonster: 1; //for new killmonster behavior unsigned int rebirth: 1; // NPC_Rebirth used + unsigned int boss : 1; enum MobSkillState skillstate; unsigned char steal_flag; //number of steal tries (to prevent steal exploit on mobs with few items) [Lupus] unsigned char attacked_count; //For rude attacked. @@ -143,7 +144,6 @@ struct mob_data { int spawn_timer; //Required for Convex Mirror struct item *lootitem; short class_; - unsigned boss : 1; unsigned int tdmg; //Stores total damage given to the mob, for exp calculations. [Skotlex] int level; int target_id,attacked_id; diff --git a/src/map/npc.c b/src/map/npc.c index c5c18aea0..d070b6886 100644 --- a/src/map/npc.c +++ b/src/map/npc.c @@ -2705,7 +2705,7 @@ static const char* npc_parse_mob(char* w1, char* w2, char* w3, char* w4, const c memset(&mob, 0, sizeof(struct spawn_data)); - mob.boss = !strcmpi(w2,"boss_monster"); + mob.state.boss = !strcmpi(w2,"boss_monster"); // w1=<map name>,<x>,<y>,<xs>,<ys> // w4=<mob id>,<amount>,<delay1>,<delay2>,<event> |