50 int max, sound_was_played;
57 for (ab = trap->
above, tot = 0; ab != NULL; ab = ab->
above)
61 if (!(trap->
value = (tot > trap->
weight) ? 1 : 0)) {
69 for (ab = trap->
above, max = 100, sound_was_played = 0; --max && ab; ab = ab_next) {
76 if (!sound_was_played) {
81 "You fall into a trapdoor!", NULL);
method_ret common_pre_ob_move_on(object *trap, object *victim, object *originator)
#define SOUND_TYPE_GROUND
#define SET_ANIMATION(ob, newanim)
void draw_ext_info(int flags, int pri, const object *pl, uint8 type, uint8 subtype, const char *message, const char *oldmessage)
void update_object(object *op, int action)
void register_move_on(int ob_type, move_on_func method)
void play_sound_map(sint8 sound_type, object *emitter, int dir, const char *action)
#define MSG_TYPE_APPLY_TRAP
void common_post_ob_move_on(object *trap, object *victim, object *originator)
static method_ret trapdoor_type_move_on(ob_methods *context, object *trap, object *victim, object *originator)
void init_type_trapdoor(void)
int transfer_ob(object *op, int x, int y, int randomly, object *originator)