http://www.neurohack.com/downloads/Trans106.zip
This release has several enhancements for modding, but likely introduces quite a few bugs. Please test carefully and let me know what you find. The major enhancements are as follows:
CURRENCIES
I've changed the way Ringer currency is implemented in order to make it easier to support. There is a new design type, called <EconomyType> which defines the currency used by a given economy block. For example:
Code: Select all
<EconomyType UNID="..."
id="rin"
currency="rin|rin"
conversion="500"
/>
currency= describes the name of the currency. Use the same syntax as item names to indicate pluralization. [The example says that the plural of "rin" is "rin".]
conversion= is the standard conversion into credits of 100 units of the currency. In this case, 100 rin = 500 credits.
You can assign prices to an item in any currency. For example:
Code: Select all
<ItemType ...
...
value="rin:75"
...
</ItemType>
The <Trade> section of a station uses the currency= attribute to specify the currency used by the station. For example, Ringer stations specify that they use rin. Prices are automatically converted as appropriate.
The following functions have been changed (in a backwards compatible fashion) to take a currency parameter: plyGetCredits, plyCharge, plyCredit, objGetBalance, objCharge, objCredit. [Also, the last three functions now work on the player ship: gPlayerShip; they should be used instead of the ply??? functions.]
objGetSellPrice and objGetBuyPrice return values in whatever currency the station uses.
You may use objGetDefaultCurrency to figure out what currency a station uses.
You may use itmGetDefaultCurrency to figure out what currency an item is priced in.
You may use ecoExchange to convert from one currency to another.
You may use fmtCurrency to format a string containing a currency value.
One other minor addition: The priceAdj= attribute in a <Trade> element now takes some special variants:
priceAdj="constant:xxx" sets the price to xxx (as opposed to adjusting the price by some percentage)
priceAdj="unavailable" means that the specified item(s) are not for sale or not bought by the staiton.
WEAPONS
I've made a few enhancements to weapons.
There is a new linkedFire= attribute on weapons. If you set linkedFire="always" then the weapon will fire regardless of whether it is the selected weapon or not. Linked weapons will fire when you press the fire weapon key; linked launchers will fire when you press the fire missile key. Note that this attribute is designed for player-ship weapons. AI ships should still use the secondaryWeapon attribute. [In fact, in the future, weapons with the linkedFire attribute may always count as secondary weapons for the AI.]
I've added some new functions: objSetDeviceFireArc and objSetDevicePos can be used inside of <OnInstall> to place a weapon at a particular position on the ship. The corresponding objGet??? functions are also implemented.
There is a new event on weapons: <GetOverlayType>. When the weapon is installed, the event fires and you may return the UNID of an overlay to install corresponding to the weapon. The overlay will be automatically removed when the weapon is uninstalled. [An easier method is to specify the overlay UNID in the weapon element using the overlayType= attribute; but the event allows you to dynamically determine whether to have an overlay or not.]
Weapons now have an <OnFragment> event. You may override the normal creation of fragments and create whatever you want (e.g., a station).
Particle-type weapons (like the PK25 Morning Star) now honor the maneuverRate= attribute. This allows for tracking particle-type weapons.
As previously described on the forums, there is a new effect type called <Beam>, which allows any missile to appear like a beam.
Weapons (and shields) have a new idlePowerUse= attribute which (optionally) specifies how much power a weapon or shield draws while idle.
I've reworked how shockwave-type weapons cause damage. See: http://wiki.neurohack.com/transcendence/trac/ticket/473 for details.
MISCELLANEOUS CHANGES
I've added shpGetAISetting and shpSetAISetting to dynamically change the AI combat parameters.
For stations, you no longer have to specify maxHitPoints or maxStructuralHitPoints. If you specify hitPoints= then we assume that maxHitPoints is equal to that. Same thing for structuralHitPoints.
I've expanded the set of sovereign alignments. In practice they don't change anything about sovereign relationships (each new alignment maps to one of the old ones for purposes of who is an enemy of whom). But the new set of alignments fits better with my plans for Part II. I'll post a fuller description soon.
There is a new <ImageComposite> element on stations. For example:
Code: Select all
<ImageComposite>
<Image imageID="{image A}"/>
<Image imageID="{image B}"/>
</ImageComposite>
GAME BALANCE CHANGES
Items that Teratons steal from the player have a 90% chance of surviving after the Teraton station is destroyed.
I've increased the chance that armor segments will survive for ships with lots of segments (e.g., Iocrym).
I've decreased the probability of insurance station spawns.
New Victoria arcology has more hit points.
OTHER BUGS & ENHANCEMENTS
As always, the complete list of bugs fixed is here: http://wiki.neurohack.com/transcendence/trac/report/14
CREDIT
I've added the following people to the credits section for reporting bugs fixed in this release:
Amariithynar
Azmond
Mist
Zerat00l
If I've misspelled you rname or you would like your name to appear differently in the credits, please PM me.