diff --git a/changelog b/changelog index c67f91ef8d2..ac715c3d670 100644 --- a/changelog +++ b/changelog @@ -1,6 +1,8 @@ Version 1.5.0+svn: * graphics: * new ford graphics from Syntax_Error + * game engine: + * poison no longer prevents resting * language and i18n: * updated translations: Chinese, Finnish, French, German, Polish, Russian, Spanish, Turkish diff --git a/players_changelog b/players_changelog index 4169adf09d0..cc3b57c297c 100644 --- a/players_changelog +++ b/players_changelog @@ -13,6 +13,9 @@ Version 1.5.0+svn: * Unit changes and balancing * Decreased the ranged attack of the Mage of Light from 15-3 to 12-3. * Decreased the melee attack of the Merman Warrior from 8-4 to 10-3. + + * Game engine + * Poison no longer prevents Resting * User interface * Titlescreen is now randomly loaded. diff --git a/src/actions.cpp b/src/actions.cpp index 5bc08602981..afde56092d8 100644 --- a/src/actions.cpp +++ b/src/actions.cpp @@ -1542,6 +1542,8 @@ void calculate_healing(game_display& disp, const gamemap& map, std::vector healers; int healing = 0; + int rest_healing = 0; + std::string curing; unit_ability_list heal = i->second.get_abilities("heals",i->first); @@ -1628,24 +1630,25 @@ void calculate_healing(game_display& disp, const gamemap& map, curer = units.end(); } if(i->second.resting()) { - healing += game_config::rest_heal_amount; + rest_healing = game_config::rest_heal_amount; + healing += rest_healing; } } if(is_poisoned) { if(curing == "cured") { i->second.set_state("poisoned",""); - healing = 0; + healing = rest_healing; healers.clear(); healers.push_back(curer); } else if(curing == "slowed") { - healing = 0; + healing = rest_healing; healers.clear(); healers.push_back(curer); } else { healers.clear(); - healing = 0; + healing = rest_healing; if(i->second.side() == side) { - healing = -game_config::poison_amount; + healing -= game_config::poison_amount; } } } @@ -2447,7 +2450,7 @@ void apply_shroud_changes(undo_list& undos, game_display* disp, const gamemap& m unit_map::const_iterator new_unit = units.find(*sight_it); assert(new_unit != units.end()); teams[team].see(new_unit->second.side()-1); - + game_events::raise("sighted",*sight_it,real_unit->first); sighted_event = true; } @@ -2470,7 +2473,7 @@ void apply_shroud_changes(undo_list& undos, game_display* disp, const gamemap& m // if (!cleared_shroud) return; // render shroud/fog cleared before pumping events - // we don't refog yet to avoid hiding sighted stuff + // we don't refog yet to avoid hiding sighted stuff if(sighted_event && disp != NULL) { disp->invalidate_unit(); disp->invalidate_all();