Announcement

Collapse
No announcement yet.

Making Cradle 3+ fully compatible with the Apolyton Edition

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Kull
    replied
    Civilian Unit Groups: While working on the new Unit Upgrade system (as described in Post #9) - and remembering some of my previous Cradle games that lasted well into the modern era - I decided to take a comprehensive look at the various Civilian units in Cradle. The biggest issue being the prolongation of Ancient-appearance units well into future ages, and some questionable upgrade paths. Let's take a look at each group, by category:

    Abolitionist: There's only one unit for this function, but given the timing and history of the abolition movement (and lack of ancient era equivalents), along with the "same period" end of Slavery as a CtP2 institution, well, no change is needed.

    Slaver: Again, a single specialized unit for this role, but the CtP2 sprite is appropriately garbed for the early era periods. Theoretically the CtP1 "red-shirted fat guy" could be added as an Industrial-era upgrade, but it would only exist for a short period. So *maybe* that might be done at some point, but definitely not on the priority list.

    Nomad: The unit which creates new Ctp2 cities. Four units in Cradle (Nomad, Settler, Urban Planner on land & Sea Engineer for water cities). The "Settler" sprite has been repurposed as "Plunder", with the Nomad sprite doing double duty (there isn't really a good alternative), but otherwise fine. However, I will knit the three land units together using the Unit Upgrade system.

    Assassin: A Cradle unit which repurposes some of the CtP legal attacks in order to target Wonder Units, City Governors and various other civilian units. Ingenious, really, but the sprite is the CtP1 Hypaspist, and it never upgrades (although unbuildable after the discovery of Communism). So it lingers on, well into the modern and future eras. A candidate for improvement, which I'll discuss in a separate post.

    Emissary: An interesting Cradle unit which repurposes some of the CtP commercial attacks in an Ancient-era fashion. First available under City State, it is eternally buildable (so you have an ancient Greek wandering around carrying a scroll, into the modern Era and beyond), but fortunately there's a clear upgrade path to the Commercial line of civilian units. Another unit series to be examined in detail.

    Clerics: Cradle has four units of this type (Prophet, Cleric, Patriarch, and Televangelist), so there's a lot we can do. To be examined later.

    Spy: The first unit arrives with Republic, and the upgrade path moves from there to Communism (Revolutionary) and eventually to Neural Interface (Cyber Ninja). There are some issues (and opportunities) with that, also to be discussed in an upcoming post.

    Lawyer: One modern-era unit. Never expires. More can be done.

    Diplomat: The toga-clad diplomat arrives with the Dynasty advance, and lasts all the way until his replacement (Empathic Diplomat) becomes available with Gene Therapy. There's a big gap in the middle which needs to be addressed.

    So that's the group, and it isn't small!

    Leave a comment:


  • Kull
    replied
    City Sprites: The source code project increased the number of city sprite slots to 255 (from 200), so let's see how they are being used in Cradle. First of all, Cradle still uses the "original" set of CtP2 sprites, not that one has many choices. There is a sub-mod which created new ones from Civ3 - which theoretically gives more stylistic variation - but to me they are a bit "muddy" in appearance and not as clearly distinctive from one civ to another. That said, there's a pretty limited number of original-style sprite groups in CtP2: Roman, Asian, Mayan, Arabian, Egyptian, and Castle. There's a seventh group called "Palace", but it has garish green roofs and the architecture begins in late Middle Ages (thus not usable in Cradle). On the plus side, BureauBert created a full set of sub-saharan African city sprites which fit this stylistic look, and so I'll be adding those for Kush and Zulu in Cradle 3+ (see attached example).

    Which brings us back to the original point - availability of Sprite slots. The 8 City Styles mentioned above use 19 sprites each, plus there's quite a few reserved for Computer, Genetic, Diamond, and Future ages, along with another three groups for underwater and space cities. Accounting for duplicates and the 19 assigned to the new "African" group, that leaves 39 open slots (even without using those assigned to things like CtP1 "space cities"), which is enough for two more City styles (at 19 slots each). That's important, because 8 of 33 Cradle civs are "ancient Near Eastern" in culture, and there isn't a single city style which is even remotely appropriate for them. "Arabian" Babylonians or "Mayan" Sumerians is something I tolerated over time because the mod is so much fun, but it's definitely a problem (The good news: I'll preview a solution in an upcoming post).

    Related to all this is the conversion of "civilisation.txt" over to the new AE format. It offers a number of benefits, to include assigning the city styles discussed above, adds the ability to link a female emissary photo (or use national flags in the diplomatic window), and even allows for assigning a flag to the "on-map" unit sprite stacks. The latter is not implemented in Cradle (IMO, flags aren't appropriate for the era), but I've left the text in place. Here's one example: # NationUnitFlag MAPICON_GREEK_FLAG. For those who may want nation flags, simply delete the "#" at the start of the line and they'll appear in game. Click image for larger version

Name:	African city sprites.JPG
Views:	238
Size:	26.6 KB
ID:	9439958

    Leave a comment:


  • Kull
    replied
    Tile Improvement Sounds: Another nice addition from the source code team was giving tileimp.txt the ability to associate sound directly with tile improvements (the 5th line of text for every entry). Previously sounds were completely omitted from this aspect of the game, but Martin Gühmann added slic code (soundfix.slc) which worked around the issue. However, the Cradle3+ conversion moves all those sound links directly into tileimp.txt, so the slic file is no longer required.

    As part of that effort, I also added a lot of new sound files, primarily for Goods. So you get alligator grunts, camel snorts, a less-ear piercing elephant screech, and actual recordings of sea creature sounds from lobsters, whales, and mollusks. I also made a few changes to the mineral and vegetable Goods, but there's not a lot one can do with those (what DOES a potato sound like?) Along the way, I noticed that construction sounds were absent from Watch Towers and Stone Roads, so those were added as well.

    Leave a comment:


  • Kull
    replied
    "Belfroi" unit: The Great Library, the Sprite, and the 2D unit pix portray this as an early form of catapult, but the name actually is that of a siege tower. And even if the graphics were correct, "city siege" isn't a feature in CtP2, so there's no point in having a "Belfroi" unit. Hex undoubtedly recognized the problem, since Cradle4 changed the graphics to show a Ballista (a device which hurls a giant arrow-like weapon at walls and men), but the unit name and text descriptions were not updated to match. However, a complete shift from Belfroi to Ballista (name, GL, pix, and sprite) is included with Cradle 3+

    Leave a comment:


  • Kull
    replied
    Natural Wonders: Speaking of "eye candy", there's an old mod which adds seven "Natural Wonders" to the map, and - as with the slic code that deploys "Visible Wonders" - there can never be more than one of each anywhere on the map. These include the Urgup Cones (Turkey), Guillin Hills (China), Lake Baikal (Russia), Ayers Rock (Australia), Great Barrier Reef (Australia) and a generic Waterfall and Canyon.

    I studied the way in which this mini-mod was incorporated into the "Modern Times" mod and was able to get it working in Cradle 3+. However, it was disappointing to find that not all of them would necessarily appear on the map, and some didn't look so great even when they did. So I played around with the slic code and made the following fixes:

    - Lake Baikal: It was appearing in plains hexes, but the reality is that Baikal is noteworthy for it's high altitude and mountainous surroundings. So now it appears in the middle of a mountain range, and the effect is much more dramatic (see attachment).

    - Great Barrier Reef: These are generated on existing Reef tiles, but - for whatever reason - the map generation code does a poor job of adding Reef tiles to the map (by contrast kelp is everywhere), so this Wonder was rather rare. I altered the code by adding a conversion of some Kelp tiles to Reef, so not only does this wonder always appear, but there's now a lot more reef tiles on the map, many of which add visual diversity to the ubiquitous "kelp gardens".

    - Ayers Rock: It wasn't uncommon for the code to deploy this graphic on a shoreline tile, which was an ugly look since the "Rock" would hang out into the neighboring beach tile. And besides, it's an inland Wonder anyway. The code has been fixed to eliminate shoreline appearances.

    - The Falls: The code ensured they could only be built on hill tiles at the beginning of a river system, which made their appearance very rare. But the fact is that most waterfalls appear somewhere along the course of a waterway, so I added code to that effect and now this Wonder is much more common.

    More generically, I added code to keep all the land wonders (except the Waterfall) from appearing on River tiles (an ugly look), nor do they share tiles with Goods (another ugly look) plus they can no longer be pillaged and you can't build other tile improvements on top of them (which effectively wiped them off the map). Click image for larger version  Name:	Lake Baikal.JPG Views:	1 Size:	45.0 KB ID:	9439701

    Leave a comment:


  • Kull
    replied
    By today's graphical standards, it's almost laughable to rave about the "interesting animation" of CtP1 sprites, but they had motion and a 3D appearance and were a vast improvement over the comparable units in their closest gaming competitor, Civ2. So don't laugh (too hard, anyway), as this next attachment shows one of several "advertising displays" that rotate across the panel as the subNeural Ad moves from place to place: Click image for larger version

Name:	SubNeural Ad panel.JPG
Views:	240
Size:	19.3 KB
ID:	9439698

    Leave a comment:


  • Kull
    replied
    At this stage of it's existence, CtP2 is a 20 year old game with a limited following, but even to this day, you can read posts around the Internet (reddit, GoG forums, etc) from folks who are still nostalgic about the game. In particular, they recall the interesting way in which CtP1 portrayed future units like the "TV-Head" evangelist or BureauBert and his traveling corporate desk. The craziest looking units were those from CtP1, but because most of those sprites don't have the Idle Animation (as I discuss in this thread), their motion is truncated, and even when brought into CtP2 (as many mods have done), they are just shadows of their formerly interesting selves.

    It's paradoxical I suppose, that while working on the Cradle mod - heavily focused on the Ancient World - I began to miss those fascinating old units. And so, one-by-one, I've been deconstructing and rebuilding many of those sprites in order to restore their full animation. And they WILL have a place in Cradle. Remember, Cradle still has most of the CtP future techs, and thus there's plenty of room to fit them into the late game, even though - realistically - many games won't make it that far into the future.

    But who knows, maybe some of these reinvigorated future sprites might find their way into other mods and regardless it's gratifying to see them functioning as they once did. For example, the "Subneural Ad" is a blimp-like unit that carries full-motion advertising panels on it's sides. Those panels were condemned to a dark, unchanging appearance, but not any more (Edit: Gah! That's a small gif showing the SubNeural Ad unit in motion, but apparently the motion part doesn't work for embedded files): Click image for larger version  Name:	SubNeural Ad.gif Views:	1 Size:	41.0 KB ID:	9439696
    Last edited by Kull; June 3, 2022, 12:05.

    Leave a comment:


  • Kull
    replied
    Stone Roads graphics issue: A very minor issue, but the "Tile" tab on the selection interface is where the player chooses which Tile Improvements to build. Although the Cradle picture directory includes a Stone Road graphic, even in Cradle4 the visual menu showed the same graphic (top image) for Roads and Stone Roads - and the GL entry did as well. Both issues have been fixed in Cradle 3+ (bottom image).Click image for larger version  Name:	Stone Road graphics issue.jpg Views:	2 Size:	107.6 KB ID:	9439688

    Leave a comment:


  • Kull
    replied
    Veteran Stacking "Bug": Several of the Wonder Units are said to "grant veteran status" to any units they are stacked with. This is not a built-in game feature, but is controlled by slic code in the "wonderunits.slc" file. That in turn is modified code from the Activision-created Alexander scenario. I've always been a bit intrigued as to how that would work, since the code itself seemed to be very simple in nature, mostly focused on identifying those units to which it would NOT apply.

    I spent some time studying the Alexander scenario, looking for evidence of the code in action, and there's no doubt that it works. Units which start a turn in the same hex with the Alexander unit ALL had Veteran status, clearly visible with the Veteran unit flag. This status wasn't conditional on staying with Alexander DURING the turn - they remained "Veterans" even when moving separately. However, any units which were not stacked with Alexander at the end of the turn, LOST VETERAN STATUS at the beginning of the next turn.

    Which explains why the code is so simple. It completely alters the Veteran mechanism, assigning and removing it ENTIRELY on the basis of whether a unit is stacked with a "Veteran-status-granting" unit. For example, even units that gained Veteran status normally - during combat - lost it at the start of the next turn.

    Interestingly, the code never actually worked in Cradle. Units that supposedly granted the status - did not. So rather than try to impose a questionable mechanism, I've opted to remove all mention of it from those Cradle units which allegedly had this power.

    Leave a comment:


  • Kull
    replied
    Two different "Emerald Goods": Unique among the on-map Goods there are two Emeralds, each with a different "sprite". Those in polar regions feature a bluish triangle-shaped gem, while those in mountain terrain use the original CTP rectangular green. They have the same stats, but importantly, Emeralds aren't found in polar regions, nor do they look much like the triangular ones we see in-game. This seemed like a good opportunity to substitute something a little more "region-appropriate".

    Which is what you see in the attachment. A newly created "Polar Bear" sprite replaces the Polar Emeralds, with new stats and a write-up in the Great Library. As a helpful by-product, I spotted a statting problem with the "Mountain Emeralds" which prevented them from appearing in the GL, but that has been fixed as well. Click image for larger version  Name:	Polar Bear Good.JPG Views:	1 Size:	241.9 KB ID:	9439681

    Leave a comment:


  • Kull
    replied
    Originally posted by Carolus V. View Post
    Hello Kull. First of all I want to say, that this is a very ambitious venture. Respect for that. And maybe I can help you a bit with this Elite.slc Problem, if it is a Problem for you anyway. There are two lines in the Const.txt file which will give you on the one Hand Elite Units, and on the other Hand Leader Units. These are namely:
    COMBAT_ELITE_CHANCE 0.20
    COMBAT_LEADER_CHANCE 0.05
    0.20 and 0.05 are the Chances to get either an Elite Unit or an Leader Unit (out of an Elite Unit) if succsseful in Battle, no matter if you are the Attacker or the Defender. One Thing wiith Leaders is you have to specify this (Leader) Unit in Units.txt.
    So maybe, I could´ve helped you a bit, and if you knew this already than my apologies.
    Finally I´m very pleased that CTP II isn´t truly dead.
    Thank you for your Afforts.

    Walter
    Thanks for looking into that. There's definitely a terminology issue at work here, because there are two completely different meanings for "Elite Units"

    1) In Cradle, victory in battle can result in some units being upgraded from "normal" to an entirely different unit. For example, the basic Spearman could be "promoted" to a new unit called "Elite Spearman". Different stats, different entry in units.txt, everything. All this is handled by a SLC file called "updater.slc".

    2) The Source Code project added a new in-game promotion possibility for units which goes one step beyond "Veteran". In that case, Veterans can be promoted to "Elite", but it's the same unit, just with improved stats. This is the "Elite" code you spotted in Const.txt, but it has no effect on the "Cradle Elite" issue.

    That said, the two systems are fully compatible, and eventually I expect that we'll see in-game instances where some "Cradle Elites" are promoted to "Source Code Elites".

    Anyway, the updater.slc code works fine under normal circumstances, but it collapses when trying to do partial upgrades (i.e. when the player is given the choice of updating some (but not all) Cradle Elites to a higher unit level. I probably can't fix that, so eventually - unless a SLIC coding expert shows up and is able to identify the problem in the code - I'll try to identify and remove the offending portion of the code, although I'm not a coder by training.
    Last edited by Kull; June 2, 2022, 19:41.

    Leave a comment:


  • Carolus V.
    replied
    Hello Kull. First of all I want to say, that this is a very ambitious venture. Respect for that. And maybe I can help you a bit with this Elite.slc Problem, if it is a Problem for you anyway. There are two lines in the Const.txt file which will give you on the one Hand Elite Units, and on the other Hand Leader Units. These are namely:
    COMBAT_ELITE_CHANCE 0.20
    COMBAT_LEADER_CHANCE 0.05
    0.20 and 0.05 are the Chances to get either an Elite Unit or an Leader Unit (out of an Elite Unit) if succsseful in Battle, no matter if you are the Attacker or the Defender. One Thing wiith Leaders is you have to specify this (Leader) Unit in Units.txt.
    So maybe, I could´ve helped you a bit, and if you knew this already than my apologies.
    Finally I´m very pleased that CTP II isn´t truly dead.
    Thank you for your Afforts.

    Walter

    Leave a comment:


  • Kull
    replied
    Updater.slc: Unfortunately the new system does not apply to the Cradle Militia (garrison units created when a city is founded) or Cradle Elite units (government-specific land units which who can receive "battlefield promotion" into non-government-specific units of an improved type). Because these Militia/Elite units are - by definition - unbuildable, there's no way to upgrade them normally, so the SLIC system is still utilized for this subset of unit types. The good news is, it has been improved! The old code only gave you one chance to upgrade, for example, from Elite Legion to Elite Pikeman. Miss that opportunity and you were stuck with Elite Legions forever. But stripping out all the non-Elite/Militia upgrade code (now handled by the built-in upgrade system described in the post above) cut the file size by more than half, and allowed me to add upgrades from every lower level to any higher one. For example, Hoplite Elites can be upgraded directly to the highest available level. So upgrades from Hoplite Elite to Pikeman Elite, Arquebusier Elite, Infantryman Elite, Machine Gunner Elite and even Hover Infantry Elite are all possible.

    This increase in the number and types of possible upgrades identified a problem with the original update code. For some reason, if you choose a "partial update" - upgrading some units of a particular type instead of "All" - the code shuts down without warning after the second time it runs. And that applies whether the "second time" is in the same series of updates or those chosen during a different turn. Fortunately this does not cause a CTD, and you'll only get a warning message if Debugslic=Yes (see below). I've looked at the code but the complexity is well beyond my ability to understand, much less fix. The only solution I can suggest (and remember - this is not a new issue, but one that has always been present in the code as verified by testing a non-AE Cradle install) is to avoid "partial updates". If you don't have the money to do all of them, wait until the next opportunity - of which you now have plenty!

    Edit: This problem has been solved – see Post# 64 below.​

    Click image for larger version  Name:	Updater Error.JPG Views:	1475 Size:	12.9 KB ID:	9438632
    Last edited by Kull; November 25, 2025, 17:28. Reason: Added link to "solution" post

    Leave a comment:


  • Kull
    replied
    Unit Upgrades: One of the best new features of the Apolyton Edition is the built-in unit upgrade system. It's controlled by a button on the interface, and the human player can update units at any time and in any order. The AI has this benefit applied to all affected units immediately after discovering the associated advance, which definitely adds to the "degree of difficulty". After a lot of research, all "non-Special" Cradle units now have the complete upgrade path added to units.txt. Transport-type ships now upgrade from Coracle-to-Crawler, artillery types from Belfroi-to-War Walker, missile units from Slinger-to-Hover Infantry, etc.

    Click image for larger version

Name:	Slinger Upgrade.JPG
Views:	1521
Size:	88.3 KB
ID:	9438626

    Leave a comment:


  • Kull
    replied
    "Const.txt": As the name implies, many of CTP2's "constants" can be found in this file. A comparison of the Cradle file vs. the AE version (Winmerge is very helpful in this regard) identified a number of improvements (AE has 8 new settings appended at the bottom of the file), so Cradle 3+ uses the new AE file. Although I kept a majority of the Cradle settings (most of which come from the base game or were borrowed from MedMod), in a few cases I went with the AE settings or my own. For example, I altered the river settings and now you see more of them (and longer) in Cradle 3+ games.

    Leave a comment:

Working...
X