Cymek mod (alpha), bugs and questions

A place to discuss mods in development and concepts for new mods.
Post Reply
howerj
Anarchist
Anarchist
Posts: 4
Joined: Tue Dec 10, 2024 4:38 pm

Ahoy!

I have been a long time player of Transcendence and have decided to pick it up
and update a mod I made circa 2009. I have a few issues however with it, a few
bugs and also a few minor balance issues. The mod incorporates some items from
other mods and credits them.

The mod is available here: https://github.com/howerj/transcendence-mod-cymek,
you will have to compile it yourself, as I have not added a release yet.

The mod adds various items, the main ones being:
  • A deployable container habitat that the player can name and use to store
    items. Unfortunately I could not get the cargo capacity check to work so you
    can store as many items as you like. This is not as bad as it sounds, because
    it functions much like a jettisoned item, just slightly more protected and
    more organized. Nomads will not search the container as well.
  • An installable nano-factory which can craft many low to medium tier items.
  • An installable CDM shard, much like from the extension Eternity Port, with only
    one power. The original mod had a similar device, but I've updated it so it more in
    keeping with the surrounding lore. It also acts like a slot-less Quantum CPU,
    but is much less powerful than the Eternity port version.
  • A modified Hornet Battle Pod, which unfortunately is missing the
    "miscellaneous devices" screen and few others when doing dock services, and I do not
    know to fix it, this is the second bug, but a more major one. It seems to prevent
    the black market being able to install smugglers cargo holds.
I also want to put the new ship as an option in the Eternity Port story line,
but I do not know how to do this.

There are some other items as well, but they are less important.

Any hints about the bugs would be helpful, or how to add custom player ships to
Eternity Port. Also does anyone know how to make lower level external weapons?
The ones that put a little sprite on your ship?

Thanks,
howerj
User avatar
Aury
Fleet Admiral
Fleet Admiral
Posts: 5465
Joined: Tue Feb 05, 2008 1:10 am
Location: At the VSS Shipyards in the frontier, designing new ships.

Hi! Some pointers:

Playerships can be made starter ships in EternityPort by adding the following attribute to their attributes list:

Code: Select all

00900000_PlayerShip
Your UNIDs (unless you are defining the UNID of a different extension or library to import) should all be within the same range (you are using two different ranges there, D008 (which appears to be someone else's range) and D539 (which is unassigned)). If you need a range, feel free to request an available range not already in use: https://wiki.kronosaur.com/doku.php/mod ... d_database - it looks like D539 is available.

We have historically had some inter mod copyright issues come up in the past.
- If the mod has a permissive license (open or copyleft) then you can include it, but do redistribute a license notification for that portion of the content - its usually required by the terms of the license, and is generally good form to reduce confusion
- If the mod does not have a permissive license, then you need to require it as a dependency (ideally also provide a download link for users of your mod), and you can use <[Type]Override> of fulll overwrites of type definitions as needed to change things.
(shpOrder gPlayership 'barrelRoll)

<New tutorials, modding resources, and official extension stuff coming to this space soon!>
howerj
Anarchist
Anarchist
Posts: 4
Joined: Tue Dec 10, 2024 4:38 pm

Thanks for the tips! I have requested the ID and made updated the IDs in the mod already. I'll track down the licenses of the mods and resources I used, I would prefer to release my mod under as liberal license as possible.
relanat
Militia Captain
Militia Captain
Posts: 954
Joined: Tue Nov 05, 2013 9:56 am

i had a quick look at your mod. Nice work.

I have a few ideas for the cargo hold problem . Not sure if any of them will do anything.
Maybe try increasing the 'mass', 'size' and/or 'maxCargoSpace' value to see if that brings up the 'Misc Devices' screen. There might be something in the game that stops small ships from having this.
Or fit a cargo hold as standard equipment and remove it with code before the game starts.
You could also try using the newer code layout which has a "Hull" element. here is an example from 'CommonweallthShips.xml'.

Code: Select all

	<ShipClass UNID="&scBorerStock;"
			manufacturer=		"United African States"
			class=				"Borer"
			type=				"gunship"

			attributes=			""
			inherit=			"&baHumanTechShip;"
			>

		<!-- Hull -->

		<Hull
			size=				"31"
			mass=				"120"
			cargoSpace=			"250"

			maxReactorPower=	"10000"
			maxCargoSpace=		"250"
			maxDevices=			"8"

			maxArmor=			"heavy"
			stdArmor=			"heavy"
			/>

		<Drive
			maxSpeed=			"10"
			thrust=				"480"
			/>
		
		...
Or maybe you could try making an external smuggler's hold.
Speaking of which, the code for external devices is in ''RPGAuxDevices.xml'.

For the player cargo container you could try adding code to the dockscreen which disables the 'Jettison' action if the total mass of the current contents exceeds your desired cargo space. That code is a bit complex so if I get a chance I''ll have a look at it in the near future (no promises though!).

Hope that helps.
Stupid code. Do what I want, not what I typed in!
relanat
Militia Captain
Militia Captain
Posts: 954
Joined: Tue Nov 05, 2013 9:56 am

I got some time to play the Hornet. Very zippy, I like iit. Now I see what you mean about the Misc Devices screen not appearing.
It is an easy fix. Your mod is using API Version 22 (from around 2009 I guess). The current game version, 1.9, uses API 53. This is a backwards compatibility thing allowing older mods to run in newer game versions.
If you change your code to look like the following the ship will display the current dock service screens. Change the 'apiVersion=' to 53 and add the HumanSpaceLibrary line of code.

Code: Select all

<TranscendenceExtension 
	UNID="&UNIDExtensionHornet;" 
	apiVersion="53" 
	name="Cymek Industries" 
	credits="howerj/HornetBattlePodsRule <https://github.com/howerj/cymek>, darksider (barrel bomb), FAD's hornet battle pod mod, Shivian Hunter's hornet battle pod mod, Soggydoggy's one piece armor mod, and more!"
	>
	<Library UNID="&unidHumanSpaceLibrary;"/>
	
	<Image UNID="&rsArmorHUDShip_Hornet;" bitmap="resources/ArmorHUDShip_Hornet.jpg"/>
	...
The cargo space limit in the deployable habitats is a bit trickier.
The code is working fine. The problem appears to be that stations, as opposed to ships, don't recognize a cargo space limit. The function 'objGetCargoSpaceLeft' for the habitat returns 1,000,000 tons even though your code has a 100 ton limit. It gives the same figure for barricades, shipwrecks and cargo crates.
The only option I can see is to create a custom dockscreen based on 'dsRPGJettison'. The 'objGetFitCount' and 'objGetCargoSpaceLeft' code would need to be modified or replaced.
It might be possible to add code to the 'OnPaneInit' section of the habitat's dockscreen instead but I haven't thought that through.

Getting the empty habitat to revert to an item which can be loaded back on to the ship should be possible. Have a look at the "ConvertToItem/CreateFromItem" code in RPGAutons.xml for an idea of what the code looks like. It should be simpler because you don't have to remember all the auton information, just convert the habitat back to an item.


Keep up the good work.
Stupid code. Do what I want, not what I typed in!
howerj
Anarchist
Anarchist
Posts: 4
Joined: Tue Dec 10, 2024 4:38 pm

That's great, it has fixed it. Thanks for tracking that bug down. I also made a fix so the playership can be used with the Eternity Port mod as well, and fixed the bug where the container habitats were immortal. I'll look at adding code to make the habitat undeployable using `ConvertToItem/CreateFromItem`, as you mentioned.

The cargo container limit not working is not too much of a problem, but more of a nice to have, so it might take me longer to look at that, I wouldn't worry about it too much. There not being a limit isn't game breaking, as it just a more armored Jettisoned Cargo crate with a map marker. The main reason for adding it would be a sense of realism.

I'll take a look at `RPGAuxDevices.xml` as well! Thanks for that. I have some ideas for lower level external devices which I think would be neat.

The mod is taking shape now, there's far fewer things wrong with it.
Post Reply