public inbox for xconq7@sourceware.org
 help / color / mirror / Atom feed
* Static Occupant Bonuses to Attack
@ 2003-04-23 17:22 Elijah Meeks
  2003-04-24 15:40 ` Hans Ronne
  0 siblings, 1 reply; 12+ messages in thread
From: Elijah Meeks @ 2003-04-23 17:22 UTC (permalink / raw)
  To: xconq7

I know that the following will increase a unit's
Attack (Or other attribute):
(table occupant-affects-attack
	(occupant transport XXXX))

However, it seems this can only be a percentage
increase.  Is there a way to designate an actual
bonus, so that an occupant provides, for example, a +1
attack or +1 defense?

Also, is it possible within Xconq to designate a
unit's Attack or Defense or other value as the sum of
its occupants Attack or Defense or other value?



__________________________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
http://search.yahoo.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-23 17:22 Static Occupant Bonuses to Attack Elijah Meeks
@ 2003-04-24 15:40 ` Hans Ronne
  2003-04-24 15:58   ` Elijah Meeks
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Ronne @ 2003-04-24 15:40 UTC (permalink / raw)
  To: Elijah Meeks; +Cc: xconq7

>I know that the following will increase a unit's
>Attack (Or other attribute):
>(table occupant-affects-attack
>	(occupant transport XXXX))
>
>However, it seems this can only be a percentage
>increase.  Is there a way to designate an actual
>bonus, so that an occupant provides, for example, a +1
>attack or +1 defense?
>
>Also, is it possible within Xconq to designate a
>unit's Attack or Defense or other value as the sum of
>its occupants Attack or Defense or other value?
>

Not at present. Additive effects would not be too hard to implement,
though. We have both additive and multiplicative effects in some other
cases, such as occupant-add-production and occupant-multiply-production.

Ultimately, it boils down to how many GDL tables we want to support. More
tables means more flexibility for the game writer but also makes it harder
for the novice. If I really need a new table in a game that I am writing, I
add it. But I usually look for other ways to achieve the same thing first.

Hans


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-24 15:40 ` Hans Ronne
@ 2003-04-24 15:58   ` Elijah Meeks
  2003-04-24 16:34     ` Emmanuel Fritsch
                       ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Elijah Meeks @ 2003-04-24 15:58 UTC (permalink / raw)
  To: Hans Ronne; +Cc: xconq7

I think the static bonuses stems from a more RPG style
of wargaming, and so it suits a smaller scale.  In the
case of the game I'm working on, we'll use it to
simulate the effect of various equipment on troops,
some of which would give a static bonus and some a
strength multiplier.

The second effect, determining a unit's attributes as
the sum of its occupants' attributes, is an attempt to
model customized armies, wherein the player decides
what divisions make up the army.  This would allow a
player some flexibility in designing their army (Say
they want it fully mechanized, or mobilized, or with
integral air support).  The designer would only need
to create the constituent units and then the player
has a variety of combinations to try out.

As far as I can tell, these can't quite be implemented
within Xconq as it is.  Is it possible for me to
define my own tables within GDL or does this need to
be done within the code?



__________________________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
http://search.yahoo.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-24 15:58   ` Elijah Meeks
@ 2003-04-24 16:34     ` Emmanuel Fritsch
  2003-04-24 16:42     ` Eric E Moore
  2003-04-24 23:03     ` Hans Ronne
  2 siblings, 0 replies; 12+ messages in thread
From: Emmanuel Fritsch @ 2003-04-24 16:34 UTC (permalink / raw)
  To: Elijah Meeks; +Cc: Hans Ronne, xconq7


Elijah Meeks a écrit :
> 
> As far as I can tell, these can't quite be implemented
> within Xconq as it is.  Is it possible for me to
> define my own tables within GDL or does this need to
> be done within the code?

It should be done within the code, but code is clear, 
with significant variables and file names. 

a+
  manu

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-24 15:58   ` Elijah Meeks
  2003-04-24 16:34     ` Emmanuel Fritsch
@ 2003-04-24 16:42     ` Eric E Moore
  2003-04-28  0:46       ` Hans Ronne
  2003-04-24 23:03     ` Hans Ronne
  2 siblings, 1 reply; 12+ messages in thread
From: Eric E Moore @ 2003-04-24 16:42 UTC (permalink / raw)
  To: xconq7

[-- Attachment #1: Type: text/plain, Size: 2499 bytes --]

Elijah Meeks <elijahmeeks@yahoo.com> writes:

> The second effect, determining a unit's attributes as
> the sum of its occupants' attributes, is an attempt to
> model customized armies, wherein the player decides
> what divisions make up the army.  This would allow a
> player some flexibility in designing their army (Say
> they want it fully mechanized, or mobilized, or with
> integral air support).  The designer would only need
> to create the constituent units and then the player
> has a variety of combinations to try out.
>
> As far as I can tell, these can't quite be implemented
> within Xconq as it is.  Is it possible for me to
> define my own tables within GDL or does this need to
> be done within the code?

Well, your implementation strategy won't work, but you can do a lot
with treating armies as transports. 

Something vaguely like:

(unit-type army
           (speed-min 1)
           (speed max 2)
           (speed 2)
           (capacity 7) ; 3 divisions and an integral something
           (hp 1))      ; just headquaters and the like
(unit-type infantry-division
           (hp 10))
(unit-type armor-division)
(unit-type integral-air-support)
(unit-type integral-artillery)

(define divisions (infantry-division air-support))
(define aux (integral-artillery integral-air-support))

(table unit-size-as-occupant 
    (aux army 1)
    (division army 2))

(table hit-chance
   (divisions army 100) ; it's easy to beat on headquaters
   (integral-air-support infantry-division 100) 
   (integral-air-support integral-air-support 50)
   (infantry-division infantry-division 50) 
   ; infantry are less effective against armor
   (infantry-division armor-division 25)) 

(table protection
   (divisions army 0) ; an army with at least one division in it
                      ; cannot be hit (HQ protected by troops)
   (army divisions 100)) ; the divisions however, can be hit.

(table cellwide-protection-against
   ; having air support makes being hit by other air units less likely
   (integral-air-support integral-air-support 50)
) 

(table speed-occupant-effect
   ; if the army isn't all armor, it's slower.
   (infantry-army infantry-division 50))


The only drawback to this method is that each division has to attack
individually, but the right effect can be built in.  If someone added
an action that caused all of a transport's occupants to attack, it'd
be just about done.

-- 
Eric E. Moore

[-- Attachment #2: Type: application/pgp-signature, Size: 184 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-24 15:58   ` Elijah Meeks
  2003-04-24 16:34     ` Emmanuel Fritsch
  2003-04-24 16:42     ` Eric E Moore
@ 2003-04-24 23:03     ` Hans Ronne
  2 siblings, 0 replies; 12+ messages in thread
From: Hans Ronne @ 2003-04-24 23:03 UTC (permalink / raw)
  To: Elijah Meeks; +Cc: xconq7

>I think the static bonuses stems from a more RPG style
>of wargaming, and so it suits a smaller scale.  In the
>case of the game I'm working on, we'll use it to
>simulate the effect of various equipment on troops,
>some of which would give a static bonus and some a
>strength multiplier.
>
>The second effect, determining a unit's attributes as
>the sum of its occupants' attributes, is an attempt to
>model customized armies, wherein the player decides
>what divisions make up the army.  This would allow a
>player some flexibility in designing their army (Say
>they want it fully mechanized, or mobilized, or with
>integral air support).  The designer would only need
>to create the constituent units and then the player
>has a variety of combinations to try out.

This is really two variants of the same problem, since you can use the same
additive GDL table. You would just specify that the added value equals the
occ's own attribute in the second case.

>As far as I can tell, these can't quite be implemented
>within Xconq as it is.  Is it possible for me to
>define my own tables within GDL or does this need to
>be done within the code?

You need to add a new table in table.def and also support for this table in
the kernel (e.g. combat.c in this case). This is easy to do, particularly
since you can model it on the multiplicative table already supported in the
code. I'm busy with the unit view code right now, but if you are willing to
give it a try (and also test that it works as expected) I can check in the
code.

Hans


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-24 16:42     ` Eric E Moore
@ 2003-04-28  0:46       ` Hans Ronne
  0 siblings, 0 replies; 12+ messages in thread
From: Hans Ronne @ 2003-04-28  0:46 UTC (permalink / raw)
  To: Eric E Moore; +Cc: xconq7

>The only drawback to this method is that each division has to attack
>individually, but the right effect can be built in.  If someone added
>an action that caused all of a transport's occupants to attack, it'd
>be just about done.

Another option is to use xconq's built-in support for multi-part units
(just set parts-max to something else than the default 1). You can then
build armies made up of several parts (divisions) which you can also
transfer back and forth between armies or detach to form new units as
needed. They all have to be the same type though. And it is only the hit
points of an army that increases with more parts. The offensive value
remains the same.

Hans


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-30 20:37 ` Hans Ronne
@ 2003-04-30 21:03   ` Elijah Meeks
  0 siblings, 0 replies; 12+ messages in thread
From: Elijah Meeks @ 2003-04-30 21:03 UTC (permalink / raw)
  To: Hans Ronne; +Cc: xconq7

 
> Cool! There seems to be a mixup in the files you
> enclosed, though. There is
> no file named cil-flags8x8.gif. OTOH, the file
> cil8.gif seems to be that
> file (cil-flags8x8.gif) rather than a unit image
> file. So I guess it is
> really cil8.gif that is missing?

I must've forgotten to add cil-flags8x8, which has the
8x8 pixel flags for the sides.  The file cil8.gif is
the 8x8 pixel unit icons for the divisions, so that
when they're made part of an army they're
recognizable.  I'll add cil-flags8x8.gif to the zip as
soon as I can, along with the updates I've made to the
scenario.  It should be playable without
cil-flags8x8.gif, though playable is a subjective
term.





__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-30 20:32 Elijah Meeks
@ 2003-04-30 20:37 ` Hans Ronne
  2003-04-30 21:03   ` Elijah Meeks
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Ronne @ 2003-04-30 20:37 UTC (permalink / raw)
  To: Elijah Meeks; +Cc: xconq7

>>you could limit this using cellwide-protection-for
>>(such that infantry divisions help protect infantry
>>divisions they're stacked with) a value of 75 would
>>flatten it out some.
>
>That's a great idea.  Hey, if anyone's interested,
>what I've done so far is up at:
>
>http://castironlife.sourceforge.net/xconq-cil.zip
>
>You know, if you've got too much time on your hands...
>
>
>
>__________________________________
>Do you Yahoo!?
>The New Yahoo! Search - Faster. Easier. Bingo.
>http://search.yahoo.com

Cool! There seems to be a mixup in the files you enclosed, though. There is
no file named cil-flags8x8.gif. OTOH, the file cil8.gif seems to be that
file (cil-flags8x8.gif) rather than a unit image file. So I guess it is
really cil8.gif that is missing?

Hans


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
@ 2003-04-30 20:32 Elijah Meeks
  2003-04-30 20:37 ` Hans Ronne
  0 siblings, 1 reply; 12+ messages in thread
From: Elijah Meeks @ 2003-04-30 20:32 UTC (permalink / raw)
  To: xconq7

>you could limit this using cellwide-protection-for
>(such that infantry divisions help protect infantry
>divisions they're stacked with) a value of 75 would
>flatten it out some.

That's a great idea.  Hey, if anyone's interested,
what I've done so far is up at:

http://castironlife.sourceforge.net/xconq-cil.zip

You know, if you've got too much time on your hands...



__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
  2003-04-28 15:19 Elijah Meeks
@ 2003-04-29 23:09 ` Eric E Moore
  0 siblings, 0 replies; 12+ messages in thread
From: Eric E Moore @ 2003-04-29 23:09 UTC (permalink / raw)
  To: xconq7

[-- Attachment #1: Type: text/plain, Size: 735 bytes --]

Elijah Meeks <elijahmeeks@yahoo.com> writes:

> Thanks for the suggestions, guys, I think the best
> solution for now is Eric's, though I wonder how damage
> will be applied to occupants.  Is it in order or is it
> randomly assigned?

Each occupant will be attacked separately, and whether it's
hit/damaged calculated individually.  So one division attacking 3 will
do more damage than one attacking one (in a single attack, that the 3
will wipe it out more quickly, and therefore get hit less times helps
compensate), but you could limit this using cellwide-protection-for
(such that infantry divisions help protect infantry divisions they're
stacked with) a value of 75 would flatten it out some.

-- 
Eric E. Moore

[-- Attachment #2: Type: application/pgp-signature, Size: 184 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Static Occupant Bonuses to Attack
@ 2003-04-28 15:19 Elijah Meeks
  2003-04-29 23:09 ` Eric E Moore
  0 siblings, 1 reply; 12+ messages in thread
From: Elijah Meeks @ 2003-04-28 15:19 UTC (permalink / raw)
  To: xconq7

Thanks for the suggestions, guys, I think the best
solution for now is Eric's, though I wonder how damage
will be applied to occupants.  Is it in order or is it
randomly assigned?

__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2003-04-30 20:37 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-23 17:22 Static Occupant Bonuses to Attack Elijah Meeks
2003-04-24 15:40 ` Hans Ronne
2003-04-24 15:58   ` Elijah Meeks
2003-04-24 16:34     ` Emmanuel Fritsch
2003-04-24 16:42     ` Eric E Moore
2003-04-28  0:46       ` Hans Ronne
2003-04-24 23:03     ` Hans Ronne
2003-04-28 15:19 Elijah Meeks
2003-04-29 23:09 ` Eric E Moore
2003-04-30 20:32 Elijah Meeks
2003-04-30 20:37 ` Hans Ronne
2003-04-30 21:03   ` Elijah Meeks

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).