I did some tests and found some interesting facts, but unfortunately I wasn't able to find the main thing I was looking for.
TLasers
I was able to add 3 additional lasers (indexes 29, 30, 31) and make them compatible with Split Mamba. the weapons were working w/o problems (except the missing tooltips and the need to add the weapons through the HUD).
You cannot add more lasers in X3E because of internal limits. Does X3 have the same limits i.e. max of 32 lasers? According to my previous tests, no.
However this does not mean that X3E is doing things bad nor does this imply that X3 is using 64 bit masks as was suggested.
I don't believe that X3 is using 64 bit masks because I run a simple test: I've manually (in text editor ) assigned the laser mask to value of 2 ^ 32 which should enable the 33rd laser. However I was not able to mount a s... (you get the idea).
Post by Lh_J led me to interesting theory about the 2 indexes in TLasers.
What if one of the indexes is telling x3 the "bit position"? This would mean that by enabling for example bit 3 would allow me to mount all lasers with index set to 3. Sounds great - doesn't it?
Unfortunatelly someone forgot to tell the Egosoft. So no - it does not work this way...
What are the indexes in TLasers:
- offset 5 is "index" as far as I know it is not used in any way (but further tests may be necessarry)
- offset 9 is "bullet index" - the laser will use bullet based on index supplied here. It is no longer truth (maybe it never was?) that the bullets are bound to lasers by their position in the file (as we believed it was in x2).
Thanks to Lh_J for pointing my attention to the indexes.
I was able to create my own mass driver with my own bullet which is using different damage level and custom body file.
What is needed to find out: how the laser mask really works. You should have knowledge about binary numbers and how overflow works in integers before you go to find out.
TBullets
There is a lot of unknown values, but I don't bring any news about them. Instead I will tell you how certain value which was believed to be "known" really works.
Bullet type (offset 12) - this number is in fact a bit mask (yeah - again )
What does it do? Well I don't know exactly that's why I'm posting this whole thread. Basically the flags alter some properties of the bullet.
What I found so far:
(first number is decimal bullet flag, second is in binary)
Code: Select all
repair las. 162 10100010
kyon 2 10
ion 20 10100
mass dr 96 1100000
shockwave 8 1000
flak 256 100000000
tractor 2 10
pac 1 1
mass dr + repair laser=?
tractor + kyon = beam weapons?
possible bullet flags:
0 - no special effect
1 - ? (pac)
2 - beam (tractor, kyon, repair, las tower)
4 - ? (ion) - zig zag?
8 - areal effect (shockwawe)
16 - ? (ion)
32 - ? (mass drv, repair las)
64 - (mass drv) - ammo eat
128 - (repiar las) - repair
256 - explosion effect (flak)
64 means "use mass driver ammo" - if not set, the weapon uses energy instead
I have no idea what the 32 is for. When I removed it, my mass driver was still working ok, no visible change. What on earth has repair laser in common with mass driver
Ion Disruptor:
4 - is making the "zig zag" effect. When not set, the weapon fires forward (and eats energy faster imho)
Particle Accelerator Cannon
1 - I have no idea - the flags is only set in Beta PAC, not the Alfa
Flags that are not tested but seem straightforward:
2 - beam effect - present on all beam weapons
8 - areal effect - present only on PSG (need to test what exactly it does)
256 - explosion/flak effect - present only in the flak bullets (need to test what exactly it does)
TMissiles
Here is similar breakdown of TMissiles flags by halo112358.
So that's all for today
I (as the rest of the people here I'm sure) would really appreciate if someone could play with the flags for a little longer and find out more.
When determining what the "flag" is doing, bear in mind that what you see is combination of "launch effect", "body file" and possibly the flag itself.