dangerous terrain: corrects a problem in combat mode
This commit is contained in:
@@ -50,7 +50,7 @@ short combat_percent[20] = {
|
||||
150,120,100,90,80,80,80,70,70,70,
|
||||
70,70,67,62,57,52,47,42,40,40};
|
||||
|
||||
short who_cast,which_pc_displayed;
|
||||
short who_cast;
|
||||
eSpell town_spell;
|
||||
extern bool spell_freebie;
|
||||
extern eSpecCtxType spec_target_type;
|
||||
|
@@ -392,7 +392,9 @@ bool check_special_terrain(location where_check,eSpecCtx mode,cPlayer& which_pc,
|
||||
if(mode == eSpecCtx::OUT_MOVE && out_boat_there(where_check))
|
||||
break;
|
||||
//one_sound(17);
|
||||
for(short i = mode == eSpecCtx::COMBAT_MOVE ? univ.get_target_i(which_pc) : 0 ; i < 6; i++)
|
||||
for(short i = mode == eSpecCtx::COMBAT_MOVE ? univ.get_target_i(which_pc) : 0 ; i < 6; i++) {
|
||||
if (i<0 || i>=6)
|
||||
break;
|
||||
if(univ.party[i].main_status == eMainStatus::ALIVE) {
|
||||
if(get_ran(1,1,100) <= ter_flag2) {
|
||||
switch((eStatus)ter_flag3){
|
||||
@@ -448,9 +450,10 @@ bool check_special_terrain(location where_check,eSpecCtx mode,cPlayer& which_pc,
|
||||
case eStatus::MAIN: case eStatus::CHARM: // These magic values are illegal in this context
|
||||
break;
|
||||
}
|
||||
if(mode == eSpecCtx::COMBAT_MOVE) break; // only damage once in combat!
|
||||
}
|
||||
}
|
||||
if(mode == eSpecCtx::COMBAT_MOVE) break; // only damage once in combat!
|
||||
}
|
||||
put_pc_screen();
|
||||
if(ter_flag3 == int(eStatus::DUMB))
|
||||
adjust_spell_menus();
|
||||
|
Reference in New Issue
Block a user