Re: [Widelands-public] Possible improvement: Military sites prefer weak/strong soldiers
Status: Beta
Brought to you by:
sirver
From: Holger R. <Hol...@gm...> - 2013-05-24 04:53:16
|
On 22.05.2013, at 11:47, Teppo Maenpaa <tep...@ce...> wrote: > On Wed, May 22, 2013 at 07:22:51AM +0200, Holger Rapp wrote: > >> It is also the way things currently are: if you juggle your soldiers at the >> border, you take the risk that a not fully occupied military site gets >> attacked. That is fine imho. > > I agree. I would use the current version as a default for new buildings. > Using the "auto-exchance" feature is voluntary. > >> The exchange feature most have three states though: prefer strong, prefer >> weak, do not automatically juggle soldiers. > > Yes. > >> Otoh, this might give the option for nice mind games (e.g. manually kicking >> out the level 0 soldier repeatedly while requesting weak soldiers, so the >> enemy thinks you only have lvl 0s). > > This has corred my mind. Works only agains human opponents. > >> There is only one military site with one soldier only and I guess it is >> regularly deconstructed again. I would not worry about this use case at all. > > This question is settled, then. > >> We have a set of save games in the repo - feel free to add more to them with >> corner cases. I once thought we could enhance this scheme by giving each >> savegame a lua script that asserts some state in the loaded game. If that >> would help you, we can set this up. > > If I do the straightforward implementation, there will not be too many corner > cases that need testing. > >>> -A way to request soldiers based on general level. >> I much prefer the weak vs strong approach. > > Not in the UI, but in the game logic: I would make it possible for the > military site to request soldiers based on general level. As an example: If > the player currenly has a (0/3/0/0) trained soldier on site, and a (2/2/2/2) > would be available, then with the current call-for-soldiers logic this guy > would be difficult to find without a brute-force search. If the military site > would in this example request a soldier with general level above three, code > would be simpler and also run faster. I would not put the general levels to > UI. > >> You could be extra clever here though and set the default for requested >> soldiers to the one of the military sites nearby (i.e. if there are three >> sites who request strong soldiers nearby, it is likely that this should also >> request strong soldiers). Or closeness to the enemy border could make a >> difference. > > I must think about it. > >> This sounds like your plan is coming together. Looking forward to the >> implementation :) > > First, I would implement at least a save for the previous upgrade, before > proceeding. Would you see a problem in merging the current, non-saving > version to trunk, to get more playtest feedback? If there is a > release-related feature freeze or so ongoing, please tell. Nothing of that sort. I merged your branch to trunk in 6569. Thanks a lot for the great contribution! > Regarding the old task, > I remember reading from somewhere that the savegames should be backward > compatible. However, in map_io/widelands_map_buildingdata_data_packet.cc > there is code like: > > if (trainingsite_packet_version == CURRENT_TRAININGSITE_PACKET_VERSION) > { > > [clip] > > } > else throw game_data_error > (_("unknown/unhandled version %u"), trainingsite_packet_version); > > which is not backward compatible, it simply rejects files that appear > incompatible. Should a loader be able to load older savegames too? Yes - we aim for 3 versions of backwards compatibility - that is why some packages seem to not be backwards compatible. > > Regards, > > > Teppo > > ------------------------------------------------------------------------------ > Try New Relic Now & We'll Send You this Cool Shirt > New Relic is the only SaaS-based application performance monitoring service > that delivers powerful full stack analytics. Optimize and monitor your > browser, app, & servers with just a few lines of code. Try New Relic > and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may > _______________________________________________ > Widelands-public mailing list > Wid...@li... > https://lists.sourceforge.net/lists/listinfo/widelands-public |