This is the mail archive of the xconq7@sources.redhat.com mailing list for the Xconq project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: More trouble in the supply code


>1. If a unit is building another unit with a consumption-per-build > 0
>of any material (e.g. mana for a cloudkeep, metal for a tower), the unit
>may end up with a negative supply of that material before it stops
>building (e.g. one might find serfs with -2/6 metal).  And whenever a
>unit's supply of any material drops below zero, the unit is completely
>incapacitated until it can restore or receive supplies that pull it out
>of "the red".

I found this bug. Units were consuming build materials twice. I will check
in a fix soon. Thanks for reporting it.

>2. Although the in-length for mana of an amulet of power is -1 (i.e.
>never receives mana from anywhere or anything), I frequently see it
>drawing mana from its transport (usually a wizard)!  It seems to me that
>it should only be able to give mana to its transport, but never take
>mana.

Two points. First, setting in_length(amulet,mana) to -1 does indeed block
the normal transfer of stuff between transports and occs which is handled
by the economy code. However, if you are running the supply code on top of
that, anything might happen. Try setting um_supply_importance(amulet, mana)
to zero. Or disable the supply code (set supply false).

Second point: drawing supplies from a transport is the normal thing for
occs to do in most games. Consider airplanes on a carrier. That's probably
why the default setting for um_inlength is zero.

Hans

Hans Ronne

hronne@pp.sbbs.se



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]