Apolyton Archive  |  Preserved copy of the Apolyton Civilization Site and its forums as they stood in September 2005. Read-only; nothing here can be posted to or replied to.  |  Forum index |  About this archive |  The 1998–2001 UBB forums
Today on Apolyton WARDELL INTERVIEW PROMO A.C.S. HISTORY CHAPTER 4 GET CIV4 /w FREE PLUS! A.C.S. PHOTO GALLERY GET A.O.M. V1.1
Apolyton Civilization Forums
main| civ2| civ3| civ4| smac| ctp2| ron| moo3| galciv| galciv2| alt| about|
ApolytonPLUS | register | search | faq | new posts | pm (-/-) | upload | members
hall of fame new! | civgroups | civgroups news | interviews | the column | radio | chat | directory | news | store | PLUS
Apolyton Civilization Forums : Powered by vBulletin version 2.0.3 Apolyton Civilization Forums > Miscellaneous > Archive > Scenario League / Civ2-Creation -Archive > New Discovery? Costless Units!
Show a Printable Version | Email This Page to Someone! | Receive updates to this thread | Report this to Apolyton news!

bottom of page
  
Author
Thread   
Pages (2): [ 1   2   ]
< Last Thread     Next Thread > Post New Thread     Post A Reply
Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Exclamation  Old Post 09-03-2002 07:40 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#1 Report this post to a moderator
New Discovery? Costless Units! Support Apolyton, buy Galactic Civilizations: Deluxe Edition

Greetings again all,

Whilst fiddling with some values of units today, I made what could be a very interesting discovery. I do not know if this has been seen before, but it resembles the odd unit movement value phenomenon being discussed here. Perhaps William Keenan or someone has already figured this out. Perhaps not...

What I did was to mistakingly set the cost of a unit to 148. I just forgot to delete the 8 when changing the cost to 14. Well, to my surprise it resulted in the wierdest thing happening... the unit in question had a NONE listed as the cost! There was no shield box to be filled in, and of course any city or specific Civ can produce any unit at no cost to them! It would just require a dedicated ultra-expensive unit slot.

This will be good for scenarios where you want a very good unit, or lots of units, to be built from a worthless city or a city that shouldn't be of value when captured. No need to make city improvements extra cheap so the player wont sell them off etc. Many unique uses for this I believe. I havent really tested it much, I don't know if 148 is the magic number or what, but here are 2 screenies to show you what I am talking about. Try it out!

And if this is a new discovery, then it has my ™ on it!

-FMK.

Attachment: example2.gif
This has been downloaded 345 time(s).

Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Arrow  Old Post 09-03-2002 07:41 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#2 Report this post to a moderator
Support Apolyton buy from Amazon

And here is a shot of Berlin making the cheapest Konigstigers known to man!

Attachment: example.gif
This has been downloaded 334 time(s).

techumseh is offline techumseh
King
of the frozen North.
Apr 1999
time: 22:18
  Old Post 09-03-2002 08:30 Visit techumseh's homepage!
Edit/Delete Message Reply w/Quote
#3 Report this post to a moderator
Avatar Enlargement: We've got the solution

I'm impressed. Good work.

ravagon is offline ravagon
King
Australia
Sep 1999
time: 13:18
Post  Old Post 09-03-2002 08:35
Edit/Delete Message Reply w/Quote
#4 Report this post to a moderator
Got spare money?

Bah. I would have replied first but the bleeping server cut me off.

Does it actually work in practice (do you get a unit each turn? - even if a city is producing no shields) or is it just a graphical thing?

Also - What's the bribe price for a zero cost unit?

Very interesting indeed

DarthVeda is offline DarthVeda
Emperor
My avatar! My precious!
Jan 1970
time: 00:18
  Old Post 09-03-2002 10:14 Visit DarthVeda's homepage!
Edit/Delete Message Reply w/Quote
#5 Report this post to a moderator
Tired of ads?

Makes me wonder what the other fields do with ludicrously high values?

The unit type slot...
The defense slot... (nuclear?)
The attack slot... (nuclear?)
The hitpoint slot...
The firepower slot...

Am I missing any?

DarthVeda is offline DarthVeda
Emperor
My avatar! My precious!
Jan 1970
time: 00:18
  Old Post 09-03-2002 10:17 Visit DarthVeda's homepage!
Edit/Delete Message Reply w/Quote
#6 Report this post to a moderator
Support Apolyton, buy Call to Power 2

Although, couldn't you just set the production to 0 and achieve the same effect?

ravagon is offline ravagon
King
Australia
Sep 1999
time: 13:18
Post  Old Post 09-03-2002 10:31
Edit/Delete Message Reply w/Quote
#7 Report this post to a moderator
Support Apolyton, buy Galactic Civilizations

quote:
Originally posted by DarthVeda
Makes me wonder what the other fields do with ludicrously high values?

The unit type slot...
The defense slot... (nuclear?)
The attack slot... (nuclear?)
The hitpoint slot...
The firepower slot...

Am I missing any?


I just started thinking the same thing after reading that quote from WK in FMK's other thread.

Move slot
Transport slot
Domain (?) slot - I've tried values up to about 9 or so and all of them crashed but I never thought to try anything that much higher...

I'm off to have a play, er, conduct a rigorous scientific investigation.

MagyarCrusader is offline MagyarCrusader
Emperor
Fascist
Jan 1970
time: 21:18
  Old Post 09-03-2002 10:33
Edit/Delete Message Reply w/Quote
#8 Report this post to a moderator
Browse Apolyton AD-FREE

I could have had uses for that back in my scen creation days... Damn you FMK for waiting so long to tell me! j/k Good work!

Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Arrow  Old Post 09-03-2002 11:18 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#9 Report this post to a moderator
Support Apolyton, buy Civilization 2

Hey everybody,

Girlfriend Shanghaied me tonite soon after making this thread. Needless to say I haven't had any time to work on this (and I am quite drunk at the moment to boot).


quote:

Does it actually work in practice (do you get a unit each turn? - even if a city is producing no shields) or is it just a graphical thing?


Take a closer look to that screenie of Berlin. The city is still producing 41 shields, its just that the unit costs zero.


quote:

Also - What's the bribe price for a zero cost unit?


Again, I'll need to play around a bit to see if there is anything strange about the units built this way.


quote:
Although, couldn't you just set the production to 0 and achieve the same effect?


Yeah, I suppose you could. I was just startled by this and didn't even think of it. I'll try that too. Perhaps entering zero for a cost might just default to 10?


quote:
Damn you FMK for waiting so long to tell me!

Damn me for taking so long to stumble upon this!

I dont know, maybe this is useless. I'll have to fiddle more with this to see whats up. Maybe the AI still sees the cost as 148 and will refuse to buy such rediculous units...


-FMK.

Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Lightbulb  Old Post 09-03-2002 11:26 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#10 Report this post to a moderator
Just as I suspected Darth... Support Apolyton buy from Amazon

Ran a quick check here, and making a unit 0 cost in fact does default it's cost to 10.

-FMK.

Henrik is offline Henrik
Emperor
The European Union, Sweden, Lund
Dec 2000
time: 06:18
  Old Post 09-03-2002 13:13 Visit Henrik's homepage!
Edit/Delete Message Reply w/Quote
#11 Report this post to a moderator
Re: Just as I suspected Darth... Support Apolyton, buy Alpha Centauri

quote:
Originally posted by Field Marshal Klesh
Ran a quick check here, and making a unit 0 cost in fact does default it's cost to 10.


No it doesnt check again
The shield row gets a little bigger but the cost is still 0!
Atleast thats how it is for improvements.

Xin Yu is offline Xin Yu
King
Emeryville, CA, USA
Jan 1970
time: 21:18
  Old Post 09-03-2002 14:14 Visit Xin Yu's homepage!
Edit/Delete Message Reply w/Quote
#12 Report this post to a moderator
Suffering from ads?

I suspected a while ago that setting too big a shield box would give a negative cost (you rush buy a unit and gain money from it). Perhaps you can test it as well.

Paul Hanson is offline Paul Hanson
King
Dilbert
Aug 1999
time: 05:18
  Old Post 09-03-2002 15:56
Edit/Delete Message Reply w/Quote
#13 Report this post to a moderator
Suffering from ads?

IIRC, this sort of thing happens on the USA 2010 scenario that comes with FW. Under the right circumstances, rushbuilding a Cyborg unit results in you receiving money.

our_man is offline our_man
Prince
Glasgow, Scotland
Oct 2000
time: 05:18
  Old Post 09-03-2002 16:22
Edit/Delete Message Reply w/Quote
#14 Report this post to a moderator
Browse Apolyton AD-FREE

Paul, Xin, this does indeed happen once a unit costs over 180 shields in FW. I think Microprose mentioned this in the manual, but they managed to fix the bug under MGE.

A classic example of this is playing as the Spanish in Jay Bee's War of Cuba. The weird thing about this is that there appears to be no discernable pattern to when you can buy a unit for a negative amount of money. For example, one turn a unit could cost you 220 shields and to buy it would give you money - the next turn it might have gone down to 215 shields and it'll cost you an absolute fortune to rush-buy. It's weird.

Paul Hanson is offline Paul Hanson
King
Dilbert
Aug 1999
time: 05:18
  Old Post 09-03-2002 21:55
Edit/Delete Message Reply w/Quote
#15 Report this post to a moderator
Get a bigger avatar today!

You're absolutely right. My friend who owned FW could get several thousand gold a turn by simply rushbuilding Cyborgs on USA 2010, whilst MGE-owning me couldn't get it to work.

And yes, the FW manual warns against setting build costs higher than 180 shields.

DarthVeda is offline DarthVeda
Emperor
My avatar! My precious!
Jan 1970
time: 00:18
  Old Post 09-03-2002 23:34 Visit DarthVeda's homepage!
Edit/Delete Message Reply w/Quote
#16 Report this post to a moderator
Got spare money?

So what's the max shield cost in MGE/ToT?

250?

Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Arrow  Old Post 09-03-2002 23:51 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#17 Report this post to a moderator
Support Apolyton, buy Alpha Centauri

I am gonna have to have some time to play around and get some findings. Beautiful day here, and the gf wont stand for me sitting in front of the pc. I will kepp testing though...

Henrik, yes it does... for units anyway. Entering 0 for a cost and looking at the shieldbox for the unit, it was a standard depth 10 shield unit.

All of this is being done with MGE as that is all I have. You guys will have to test the ToT and FW ones...

I'll also check on if you get money or something from building these units. More to come....

-FMK.

Field Marshal Klesh is offline Field Marshal Klesh
King
Klesh Marshal Field
Jan 2000
time: 00:18
Arrow  Old Post 10-03-2002 00:37 Visit Field Marshal Klesh's homepage!
Edit/Delete Message Reply w/Quote
#18 Report this post to a moderator
Support Apolyton, buy Civilization 2

Well I snuck some time for another quick test. The results are promising indeed.


When set to build these costless units any city really can build them. It isnt some graphic screw up where the units really cost 10 shields. A city that made 2 shields per turn could pump out these units.

Also, even rioting cities, which should have zero production anyway, can still pump out these units.

The units are supported as usual from the home city. Which makes me think that in the fanatic slot under a fundy gov., this technique could be deadly making free support/free build units from small little 'base' cities off out in nowhere or somesuch.

Now here is something strange indeed, when using the edit city function in cheat mode to reset cities's shield accumulation to zero, I found that cities which had just made one of these units had accumulation in the negative(-521 shields)! So I let those cities continue. They built another unit the next turn no problem. As I look now after the next turn... all the cities' progress is back to zero... no negative values anymore. Obviously, more in depth testing is needed. I would also like to see if the AI will choose these units to build. I will make their other stats (at/def) very appealing so they will want the unit. I would like to see if they are turned off to building it at all or something.

I also want to see how this effects the AI's use of cruise missile units, as it is commonly know they use a cost anaylsis to judge whether to send out a missle to strike.

Many things to test, and no time to do it right now. Argh!


-FMK.

hardjoy is offline hardjoy
Warlord
Odense, Denmark
May 2001
time: 06:18
  Old Post 10-03-2002 08:17
Edit/Delete Message Reply w/Quote
#19 Report this post to a moderator
Support Apolyton, buy Galactic Civilizations: Deluxe Edition

Very interesting discoveries, FMK! Keep up the good work! I will be following the test results closely ...perhaps even do my own bits of testing! intriguing to say the least..

ravagon is offline ravagon
King
Australia
Sep 1999
time: 13:18
Post  Old Post 10-03-2002 08:48
Edit/Delete Message Reply w/Quote
#20 Report this post to a moderator
Help yourself to an AD-FREE life

I did some playing too and got some rather odd results.
Firstly I was NOT able to reproduce the screen with the NONE unit cost. Still don't know about this one. Costs were always negative.

Unit costs of zero default to 10 shields (although it doesn't do this for improvements strangely enough where 0=0) and follows the usual pattern up to 127 (1270 shields)
At 128 (2^7) it flips to -1280 which rounds up to give the zero cost unit and thereafter continues increasing. ie: 129 --> -1270 etc, up to 200 which seems to be the max and has a shield cost of -560 (IIRC). Hence all unit costs above 127 are 0.

[This flip happens in the terrain resources too btw at the same point. 127 = 127 shields. 128 = -1280 (rounds up to 0 production)]

It works this way for the AI too, even though AI cities seem to produce a full shield box every turn (Graphical anomaly?)

An AI oddity that showed up however was a strong tendency to NOT attack with zero-cost units. I was at war with them and cheated in a horde of spies to keep an eye on their city production from turn to turn and my spies/other units were never attacked/expelled. This went on until I made peace. The AI then began expelling spies like crazy before sneak attacking with its zero-cost units on both my spies and other units but only for this turn.
The next turn business as usual. ie: His units just moving around not attacking spies or others in open terrain right next to his cities.
[Incidentally I was using the Jihad scenario and the fundamentalist and horseman slots to test all this]

One interesting thing that came to light was the ability to rush-build these zero-cost units. Cost was 0 gold and it produced the negative 1280 (using the production cost = 128) shields required to build the unit (although this didn't show up in the production box).
If you the changed the production queue to something else it showed a much much higher number of turns to build the new something due to the negative shield deficit that had to be "worked off" before applying shields to actually build it.

This might be ideal if somebody were designing a scenario and wished for cities to be unable to build anything for a number of turns before having their production resume at full strength.
It is still very cumbersome though as the minimum shield deficit seems to be 560 (from rush building a unit with a cost of 200) which is quite sizable.
All of this is completely irrelevant however if civtweak can set a cities shield production to a negative value (which I forgot to check )

[Edit: Actually, rereading FMK's post, he covered most of this anyway ]

DarthVeda is offline DarthVeda
Emperor
My avatar! My precious!
Jan 1970
time: 00:18
  Old Post 10-03-2002 09:25 Visit DarthVeda's homepage!
Edit/Delete Message Reply w/Quote
#21 Report this post to a moderator
Got spare money?

Oooh.... that will be useful...

Goingonit is offline Goingonit
Warlord
Toronto, Canada - AECCP member
Apr 2001
time: 00:18
  Old Post 10-03-2002 18:39
Edit/Delete Message Reply w/Quote
#22 Report this post to a moderator
Support Apolyton, buy Civilization: The Boardgame

Neat.

IMO, the AI douesn't take cost into account when building units.

Boco is offline Boco
Prince
who was once King for a week.
Jan 2001
time: 00:18
  Old Post 11-03-2002 07:52 Visit Boco's homepage!
Edit/Delete Message Reply w/Quote
#23 Report this post to a moderator
Watch out for Civ2 Editor resets Get a bigger avatar today!

To make a 'slow road' terrain, I had set the movecost to 205 (Road bonus =25, set to >10 to take advantage of WK's fractional movement math). Civ2 behaves oddly but reproducibly with these settings. Regular roads (and rivers) cost 1/10 mf; the new 'slow road' costs 2/10mf.

Here's the kicker: the Civ2 terrain editor squawks when it encounters an out-of-range variable. I was tweaking the 'slow road' terrain image via the Editor menu in Civ2, when it spotted the movecost was set out of range. It did me the 'favor' of resetting the movecost to 0 in the rules.txt. I wouldn't be surprised if this were not an isolated incident.

DarthVeda is offline DarthVeda
Emperor
My avatar! My precious!
Jan 1970
time: 00:18
  Old Post 11-03-2002 11:01 Visit DarthVeda's homepage!
Edit/Delete Message Reply w/Quote
#24 Report this post to a moderator
Browse Apolyton AD-FREE

Watch out for the civ2 editors period. They are far too buggy to be trusted by any serious scenario creator.

I recall several incidents where it changes the name of your civ to that of a resource and vice versa.

Heresson is offline Heresson
King
of frogs
Jun 2000
time: 06:18
  Old Post 11-03-2002 18:57
Edit/Delete Message Reply w/Quote
#25 Report this post to a moderator
Support Apolyton, buy Galactic Civilizations: Deluxe Edition

Nice discovery, I'm sure it'll be usefull in making some computer-played civ properly dangerous for You. I don't see any use for it
in human-played civ though; most of scns are enough easy already.

Boco is offline Boco
Prince
who was once King for a week.
Jan 2001
time: 00:18
  Old Post 07-09-2002 01:34 Visit Boco's homepage!
Edit/Delete Message Reply w/Quote
#26 Report this post to a moderator
Increase the size of your Attachments

*Bump*

Has anyone used costless units in a scenario?

William Keenan is offline William Keenan
Prince
New Jersey, USA, Earth, Sol, Milky Way
Sep 1999
time: 00:18
  Old Post 07-09-2002 02:54 Visit William Keenan's homepage!
Edit/Delete Message Reply w/Quote
#27 Report this post to a moderator
Get a bigger avatar today!

Greetings all. Its been awhile.

I think I can help shed some light on this topic. Most Civ unit values are stored as signed byte integers (-128 to 127). This conserves computer memory but produces odd results when larger than expected values are inserted.

More in a moment .....

Goingonit is offline Goingonit
Warlord
Toronto, Canada - AECCP member
Apr 2001
time: 00:18
  Old Post 07-09-2002 04:48
Edit/Delete Message Reply w/Quote
#28 Report this post to a moderator
Support Apolyton buy from Amazon

That gives me a new idea...

Ravagon was suggesting in the engineer/city-production thread that a Xin Yu or similar strategist could disband a city by selling its city walls and causing it to be destroyed by combat. Well, that would be a lot more balanced strategically if the city walls had negative cost! (and thus cost money to sell!) I'll test this, but it sounds practical and useful.

William Keenan is offline William Keenan
Prince
New Jersey, USA, Earth, Sol, Milky Way
Sep 1999
time: 00:18
  Old Post 07-09-2002 04:50 Visit William Keenan's homepage!
Edit/Delete Message Reply w/Quote
#29 Report this post to a moderator
Support Apolyton

..... back.

Computers do math using a base 16 system (hexidecimal), not the base 10 system (Decimal) we use.

One byte is 2 hexidecimal digits: 00 to FF

Decimal values: 0 to 255.

When a byte is signed decimal values are different
00 to 7F hex is 0 to 127 decimal and 80 to FF hex is -128 to -1 decimal. See Ravagons explaination above.

Civ2 uses signed bytes in unit values. It follows that a unit cost of 255 in the rules.txt is converted to a hex value of FF which to the computer is -1. Therefore the unit build cost would be (-1*10)=-10.

A city producing only one shield per turn will produce this unit evey turn because the total accumulated shield production of 1 is equal to or greater than the unit cost of -10.

Theoretically, a city with a -9 shield production would also produce the unit every turn. But a city with a -11 production would never produce the unit.

quote:
Originally posted by DarthVeda
So what's the max shield cost in MGE/ToT?

250?


The highest possible positive number should be 1270.

Goingonit is offline Goingonit
Warlord
Toronto, Canada - AECCP member
Apr 2001
time: 00:18
  Old Post 07-09-2002 05:02
Edit/Delete Message Reply w/Quote
#30 Report this post to a moderator
Support Apolyton, pre-order Civilization IV

Darn, it turns out that this doesn't work. Improvements, at least, have positive and accurate costs to 255, and them positive but inaccurate costs thereafter (the cost is equal to the set cost mod 256, which leads me to think that the cost is stored as an unsigned byte.)

 
Pages (2): [ 1   2   ]
< Last Thread     Next Thread > Post New Thread     Post A Reply
All times are GMT. The time now is 05:18.
Apolyton Time is 00:18.
    top of page
Rate This Thread:
archivepost
Forum Jump:
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
 




Contact Us - Apolyton Civilization Site - Support Us!

Building a better Apolyton through better information. Click here and take our poll!
Non-US visitors, click here!

Powered by: vBulletin Version 2.0.3
Copyright ©2000, 2001, Jelsoft Enterprises Limited.

Page generated in 0.0643 seconds (93.07% PHP - 6.93% MySQL) with 31 queries
Page Loading Time:

Support Apolyton: Amazon USA | Amazon UK | Amazon DE | Amazon FR |
Support Apolyton and get FREE PLUS, Buy from Chips&Bits: Galactic Civilizations | Galactic Civilizations: Deluxe Edition | Call to Power 2 | Civilization: The Boardgame | GURPS/ Alpha Centauri | Alpha Centauri | Civilization IV | Civilization III: Complete |


Front Page | Civilization IV | Civilization III | Civilization II | Call to Power II | Alpha Centauri | Master of Orion III
Rise of Nations | Galactic Civilizations | Galactic Civilizations II | Misc
Alt.Civs | Civ I | C:CtP I | About | News | Directory | Apolyton Store | Forums | Chat | Columns | Interviews | Newsletter
Scenario League | CSC | Clash of Civs | Spanish Site | CtP Maps | Cradle of Civ | WesW's Ctp1/2 Site | Civ3 Haven

apolyton.net | apolyton.com | civilization2.net | civilization3.net | civilization4.net | civilizationiv.info | calltopower.net | galciv.net | galciv2.net | moo3.net