Rework programs for trainingssites

Bug #1831066 reported by Toni Förster
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Won't Fix
Undecided
Unassigned

Bug Description

During my sleep time unification I figured out that there are some flaws with the programs for trainingssites.

Some sites have work animations some don't. That means sites without work animations have to wait 30s before they can fail because they miss food or a soldier has been removed. While those with a working animation, only have to wait 15 seconds.

Also in case of the barbarians battle arena. The working animation comes before the soldier training and after consume. This means that within a window of 15 seconds a soldier can be removed from the building without even being trained.

We should change it to a program flow like in the mines. Here a pseudo code example for the barbarians battle arena.

main prog
{ sleep 5000
  call=sleep
  call=train_evade_0
  call=animate
  call=sleep
  call=train_evade_1
  call=working
  return=no_stats
}

sleep prog {
   sleep 15000
   return=no_stats
}

working animate {
   animate=working 15000
   return=no_stats
}

evade0 prog {
   check soldier
   consum wares
   train soldier
}

I would add this to the unification branch
evade1 prog {
   check soldier
   consum wares
   train soldier
}

Tags: tribes

Related branches

GunChleoc (gunchleoc)
tags: added: tribes
Revision history for this message
GunChleoc (gunchleoc) wrote :

Is this fixed?

Changed in widelands:
milestone: none → build21-rc1
Revision history for this message
GunChleoc (gunchleoc) wrote :
Changed in widelands:
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.