X-Git-Url: https://plomlompom.com/repos/?a=blobdiff_plain;ds=sidebyside;f=src%2Fmap_object_actions.h;h=0d594d324d0f3a709e76ed3f3b5307ba48573b0b;hb=e75b508724effaad1bfd6dcf337c34a368855095;hp=e9812289e4bacd8f9657a02cac1f9e25ab958783;hpb=2dccba703435158681552b8a8aefccab79eb13f3;p=plomrogue diff --git a/src/map_object_actions.h b/src/map_object_actions.h index e981228..0d594d3 100644 --- a/src/map_object_actions.h +++ b/src/map_object_actions.h @@ -18,7 +18,7 @@ struct MapObjAct struct MapObjAct * next; uint8_t id; /* unique id of map object action */ char * name; /* human-readable identifier */ - uint8_t effort; /* how many turn the action takes */ + uint8_t effort; /* how many turns the action takes */ void (* func) (struct MapObj *); /* function called after .effort turns */ }; @@ -30,6 +30,9 @@ extern void init_map_object_actions(); /* Free MapObjAct * chain starting at "moa". */ extern void free_map_object_actions(struct MapObjAct * moa); +/* Return world.map_obj_acts MapObjAct.id for "name". */ +extern uint8_t get_moa_id_by_name(char * name); + /* Actor "mo" does nothing. */ extern void actor_wait(struct MapObj * mo); @@ -47,7 +50,7 @@ extern void actor_drop(struct MapObj * mo); extern void actor_pick(struct MapObj * mo); /* Actor "mo" tries to use inventory object indexed by number mo->args. - * (Currently the only valid use is consuming "MAGIC MEAT". + * (Currently the only valid use is consuming "MAGIC MEAT".) */ extern void actor_use(struct MapObj * mo);