summaryrefslogtreecommitdiff
path: root/src/map/mob.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/mob.h')
-rw-r--r--src/map/mob.h21
1 files changed, 4 insertions, 17 deletions
diff --git a/src/map/mob.h b/src/map/mob.h
index e7e3eb07e..8fb930e1f 100644
--- a/src/map/mob.h
+++ b/src/map/mob.h
@@ -5,6 +5,7 @@
#define _MOB_H_
#include "unit.h"
+#include "map.h"
#define MAX_RANDOMMONSTER 3
#define MAX_MOB_RACE_DB 6
@@ -47,9 +48,8 @@ struct mob_db {
int mexp,mexpper;
struct { int nameid,p; } dropitem[10]; //8 -> 10 Lupus
struct { int nameid,p; } mvpitem[3];
- int view_class,sex;
- short hair,hair_color,weapon,shield,head_top,head_mid,head_buttom,option,clothes_color; // [Valaris]
- int equip; // [Valaris]
+ struct view_data vd;
+ short option;
int summonper[MAX_RANDOMMONSTER];
int maxskill;
struct mob_skill skill[MAX_MOBSKILL];
@@ -112,6 +112,7 @@ struct mob_db* mob_db(int class_);
int mobdb_searchname(const char *str);
int mobdb_searchname_array(struct mob_db** data, int size, const char *str);
int mobdb_checkid(const int id);
+struct view_data* mob_get_viewdata(int class_);
int mob_once_spawn(struct map_session_data *sd,char *mapname,
int x,int y,const char *mobname,int class_,int amount,const char *event);
int mob_once_spawn_area(struct map_session_data *sd,char *mapname,
@@ -135,27 +136,13 @@ int mob_heal(struct mob_data*,int);
#define mob_stop_walking(md, type) { if (md->ud.walktimer != -1) unit_stop_walking(&md->bl, type); }
#define mob_stop_attack(md) { if (md->ud.attacktimer != -1) unit_stop_attack(&md->bl); }
-//Defines to speed up search.
-#define mob_get_viewclass(class_) mob_db(class_)->view_class
-#define mob_get_sex(class_) mob_db(class_)->sex
-#define mob_get_hair(class_) mob_db(class_)->hair
-#define mob_get_hair_color(class_) mob_db(class_)->hair_color
-#define mob_get_weapon(class_) mob_db(class_)->weapon
-#define mob_get_shield(class_) mob_db(class_)->shield
-#define mob_get_head_top(class_) mob_db(class_)->head_top
-#define mob_get_head_mid(class_) mob_db(class_)->head_mid
-#define mob_get_head_buttom(class_) mob_db(class_)->head_buttom
-#define mob_get_clothes_color(class_) mob_db(class_)->clothes_color
-#define mob_get_equip(class_) mob_db(class_)->equip
int do_init_mob(void);
int do_final_mob(void);
int mob_timer_delete(int tid, unsigned int tick, int id, int data);
-
int mob_deleteslave(struct mob_data *md);
-
int mob_random_class (int *value, size_t count);
int mob_get_random_id(int type, int flag, int lv);
int mob_class_change(struct mob_data *md,int class_);