I thought the denizens of the development community would be interested in some interesting facts I've determined while experimenting with the përs resource:
BUG #1 -
Quote
from Nova Bible 3/19/04 version, përs resource section **
Flags Some control bits
0x0020 Only show HailQuote when ship is disabled**
No hail is issued when this përs flag is set, regardless of whether the përs shďp is disabled in combat with the player's shďp, or the përs is given a gövt with the 0x0800 (start disabled) flag set. I really wanted to establish a short communications dialog with a disabled përs shďp for something I'm working on, but no-go. C'est la Vie. It's also interesting that in the Nova scenario all of the derelict përs resources have the 0x0020 flag set as well. I guess ATMOS tried it and then either forgot about it or just never got around to trying to get it fixed.
BUG #2 -
Quote
from Nova Bible 3/19/04 version, përs resource section **
HailQuote
Index number of an entry in STR# resource 7101, to be displayed at the bottom of the game screen (i.e. over the radio)**
and from Appendix III - Patching STR# Resources **
String Type:......Replacement 'STR ' ID range:
Hail quotes.........5000-5511**
Any use of the 5000 series STR<space> patch facility to alter STR# 7101 results in quotes being displayed that are garbled nonsense that appear to be numbers and NCB expressions from somewhere.
On the other hand, the companion STR# 7100 CommQuote patch STR<space> using the 15000 series RIDs works as documented.
There is a kluge workaround that involves replacing the entire STR#7101 resource, but that makes for guaranteed incompatibility with any other plug that uses the same workaround.
BUG #3 -
Quote
from Nova Bible 3/19/04 version, përs resource section **
Color
The color to paint this person's ship, encoded the same as
HTML colors (00RRGGBB). Set to 00000000 if unused (which is
the same as 00FFFFFF, or "pure white paint" i.e. no shading)
**
HTML color coding is 8-bits per color but përs only uses 5-bits for red and blue. Green is really weird because it only uses 2-bits.
The actual përs shďp color bit usage is:
red 0x00F80000
green 0x00000300
blue 0x000000F8
UNDOCUMENTED - (some of these may be common knowledge, but new folks are always joining us)
Any përs (or düde or flët) shďp equipped with the repair system oütf (ModType #49) will recover from being disabled in 5 seconds or less. However, a player shďp that has a repair system can take up to 30 seconds to repair itself. Unfair, I say (or at least annoying).
The përs oütf Grant function only works when there is no LinkMission specified. Put a Gxxx somewhere in the LinkMission itself as a workaround.
Granted items are not used by the përs shďp.
They could be considered as përs shďp uninstalled carried cargo that is retrieved and then installed in the player's shďp.
There are three constraints on being able to retrieve përs Grant oütfs:
1. Player's shďp must have sufficient free mass to accomodate the granted item(s).
This constraint is never ignored (i.e.- përs granting is not like Gxxx grants in this respect).
2. Player's shďp MaxGun and MaxTurret parameters may not be exceeded except on a 1st-time basis.
In other words, if the player's shďp has the maximum or greater than the maximum of guns or turrets, then the grant of any guns or turrets will not occur.
If the player's shďp has less than the maximum of guns or turrets, then a grant will occur (assuming 100% GrantProb) that can cause the maximum to be exceeded.
3. The granted oütf Max# parameter may also not be exceeded except on a 1st-time basis (see #2).
The përs resource shďp Color (including "pure white" no shading) overrides any gövt resource ShipColor parameter values.
The përs resource flag 0x0002 "Uses escape pod & has afterburner" also means that the përs is immortal. No matter how many times you destroy the përs shďp, it keeps reappearing.
The përs resource flag 0x0400 "Dont show (hail) quote when ships LinkMission is not available" is applied in one of two ways. Either some requirement within the LinkMission itself has not been met or there is no LinkMission specified at all (i.e. LinkMission = -1).
The përs ShieldMod parameter will not affect the Target Status Display shield percentage number because ShieldMod changes the shield capacity , not the current shield percentage level.
The default probability of appearance of 5% can only be increased by specifying a përs in a s˙st resource with a s˙st appearance probability of the developer's choosing.
Hope this helps, and if you've got any tidbits of wisdom to add, please do so.
Later...