? Build.log ? BuildErrors.log ? BuildWarnings.log ? BuildWarningsOnly.log ? Install.log ? PATCHES ? autom4te.cache ? revert-formations ? runbuild.sh ? runconfig.sh ? images/wreckr-stock ? kernel/DEVEL ? kernel/PATCHES ? kernel/run.c.diff1 ? lib/DEVEL ? lib/Xconq.Warnings ? lib/bellum2-rul.g ? lib/bellum2-t.g ? lib/bellum2-u.g ? lib/bellum2.g ? lib/knights.g ? lib/wreckr-m.g ? lib/wreckr-u.g ? sdl/tlspatch ? tcltk/DEVEL Index: ChangeLog =================================================================== RCS file: /cvs/xconq/xconq/ChangeLog,v retrieving revision 1.1474 diff -r1.1474 ChangeLog 16,30d15 < Fix scheduling bug caused by the use of formations. Also, < slightly streamline the formations code. < * kernel.h (is_in_formation): New prototype. < * plan.c (is_in_formation): New function. Is the given unit < presently in a formation and at the correct distance with respect < to the formation leader? < * run.c (side_move_some_units): Count number of units in formation. < Only move an unit that is attempting to maintain formation if that < unit is out of formation. Do not claim that an unit has been found < to move, when that unit has not been moved; making the claim causes < problems when formation movement is in effect. Ensure that the < 'waitingfortasks' flag is set on any formation units so that the < "auto next unit" UI code will be sure to pick them up and let the < player move them if they have leftover ACP after moving in formation. < Index: kernel/run.c =================================================================== RCS file: /cvs/xconq/xconq/kernel/run.c,v retrieving revision 1.103 diff -r1.103 run.c 577,583c577,584 < /* Check that the side can research something. */ < for_all_advance_types(a) { < if (side_can_research(side, a)) { < /* Popup the research dialog if the side has a < display. */ < if (side_has_display(side)) { < update_research_display(side); --- > /* Check that the side can research something. */ > for_all_advance_types(a) { > if (side_can_research(side, a)) { > /* Popup the research dialog if the side has a display. */ > if (side_has_display(side)) { > update_research_display(side); > } > return TRUE; 585d585 < return TRUE; 587d586 < } 657,658c656,657 < && ((unit->act->initacp > 0) < || acp_indep(unit))) { --- > && (unit->act->initacp > 0 > || acp_indep(unit))) { 668,674c667,670 < /* The busy flag should have been cleared when the unit < moved. If it is still set, it could mean that a < broadcasted action was never received by the host < and rebroadcasted. */ < Dprintf( < "Busy flag still set for %s at start of turn.\n", < unit_desig(unit)); --- > /* The busy flag should have been cleared when the unit moved. If it is still > set, it could mean that a broadcasted action was never received by the host > and rebroadcasted. */ > Dprintf("Busy flag still set for %s at start of turn.\n", unit_desig(unit)); 757c753 < int num, foundanytomove, curactor0, curactor, numdelayed, numfollowing; --- > int num, foundanytomove, curactor0, curactor, numdelayed; 776d771 < numfollowing = 0; 794,796d788 < /* Count the units which are in formations and can still act. */ < if (unit->plan && unit->plan->formation && unit_still_acting(unit)) < ++numfollowing; 809,810c801 < && (unit->plan && unit->plan->formation < && !is_in_formation(unit))) { --- > && (unit->plan && unit->plan->formation)) { 825d815 < /* Execute any tasks or pending actions that the unit has. */ 831,834c821,822 < if (has_pending_action(unit) || (unit->plan && unit->plan->tasks)) { < num += move_one_unit_multiple(unit, lim - num); < foundanytomove = TRUE; < } --- > num += move_one_unit_multiple(unit, lim - num); > foundanytomove = TRUE; 836d823 < #if (0) 840d826 < #endif 879,888d864 < /* Set waiting-for-tasks to true for any units in a formation, which < still are acting (have ACP, are not skipped, etc...). */ < if (numfollowing > 0) { < for (curactor = 0; curactor < av->numunits; ++curactor) { < unit = unit_in_vector(av, curactor); < if (unit->plan && unit->plan->formation < && unit_still_acting(unit) && !(unit->plan->tasks)) < set_waiting_for_tasks(unit, TRUE); < } < } 909,921c885,897 < if (unit->plan < && (unit->plan->asleep < || unit->plan->reserve)) < return FALSE; < /* Conditions that require further action provided < that it was not ruled out above. */ < if (acp_indep(unit) < && can_build(unit) < && !unit->buildingdone) < return TRUE; < if (has_pending_action(unit)) < return TRUE; < if (unit->plan) --- > if (unit->plan > && (unit->plan->asleep > || unit->plan->reserve)) > return FALSE; > /* Conditions that require further action provided > that it was not ruled out above. */ > if (acp_indep(unit) > && can_build(unit) > && !unit->buildingdone) > return TRUE; > if (has_pending_action(unit)) > return TRUE; > if (unit->plan) 1007,1008c983 < /* ... and independent units if we have brainless < building ... */ --- > /* ... and independent units if we have brainless building ... */ 1010,1011c985 < /* ... and human-cotrolled units that are not waiting for < tasks. */ --- > /* ... and human-cotrolled units that are not waiting for tasks. */