queue_special() return whether special was queued
This commit is contained in:
@@ -1987,8 +1987,8 @@ void special_increase_age(long length, bool queue) {
|
||||
draw_terrain(0);
|
||||
}
|
||||
|
||||
void queue_special(eSpecCtx mode, eSpecCtxType which_type, spec_num_t spec, location spec_loc) {
|
||||
if(spec < 0) return;
|
||||
bool queue_special(eSpecCtx mode, eSpecCtxType which_type, spec_num_t spec, location spec_loc) {
|
||||
if(spec < 0) return false;
|
||||
pending_special_type queued_special;
|
||||
queued_special.spec = spec;
|
||||
queued_special.where = spec_loc;
|
||||
@@ -2000,6 +2000,7 @@ void queue_special(eSpecCtx mode, eSpecCtxType which_type, spec_num_t spec, loca
|
||||
run_special(queued_special, nullptr, nullptr, nullptr);
|
||||
else
|
||||
special_queue.push(queued_special);
|
||||
return true;
|
||||
}
|
||||
|
||||
void run_special(pending_special_type spec, short* a, short* b, bool* redraw) {
|
||||
|
@@ -20,7 +20,7 @@ void teleport_party(short x,short y,short mode);
|
||||
bool run_stone_circle(short which);
|
||||
void change_level(short town_num,short x,short y);
|
||||
void push_things();
|
||||
void queue_special(eSpecCtx mode, eSpecCtxType which_type, spec_num_t spec, location spec_loc);
|
||||
bool queue_special(eSpecCtx mode, eSpecCtxType which_type, spec_num_t spec, location spec_loc);
|
||||
void run_special(eSpecCtx which_mode, eSpecCtxType which_type, spec_num_t start_spec, location spec_loc, short* a = nullptr, short* b = nullptr, bool* redraw = nullptr);
|
||||
void run_special(pending_special_type spec, short* a, short* b, bool* redraw);
|
||||
|
||||
|
Reference in New Issue
Block a user