[ external image ] [ external image ]
This database and it's belonging tools have been developed to be used by other scripters and modders for their (non-commercial and free) projects. If you like to use this database and it's belonging tools for your projects, I'll be pleased if you tell me about. I just ask you to mention me namely in this context and to link to this topic.
Commercial use and distribution of this database and it's tools is prohibited, unless you got my permission first.
Description
This database provides the collision avoiding distances for each axes from a objects coordinate zero point.
These distances only apply to freshly built objects, that means the alpha-angle must be 180°, all the other angles 0°. If one or more angles differ from that, you need to calculate the new distances for these angles first.
This database is provided as a language file, so you can use it easily in your scripts. The entries of each object have the following format:
<!-- Argon Chip Plant (827) -->
<t id="60210">844</t>
<t id="60211">773</t>
<t id="60212">496</t>
<t id="60213">147</t>
<t id="60214">764</t>
<t id="60215">448</t>
<t id="60216">180</t>
<t id="60217">0</t>
<t id="60218">0</t>
Access to the respective t-index of the language file can be achieved inside the script using the following formula:<!-- Argon Chip Plant (827) --> ... Name of the object
<!-- Argon Chip Plant (827) --> ... Object size according to Egosoft own script command
<t id="60210">844</t> ... Maintype of the object
<t id="60210">844</t> ... Subtype of the object
<t id="60210">844</t> ... Index and distance of positive x-axis
<t id="60211">773</t> ... Index and distance of negative x-axis
<t id="60212">496</t> ... Index and distance of positive y-axis
<t id="60213">147</t> ... Index and distance of negative y-axis
<t id="60214">764</t> ... Index and distance of positive z-axis
<t id="60215">448</t> ... Index and distance of negative z-axis
<t id="60216">180</t> ... Index and angle alpha in degrees
<t id="60217">0</t> ... Index and angle beta in degrees
<t id="60218">0</t> ... Index and angle gamma in degrees
$text.id = Maintype * 10000 + Subtype * 10 + Axis-index
The script relevant value for the angle can be obtained with the following formula:
$angle = angle * 65535 / 360
The tools
The tools are used to create an own database automatically. That's usefull if you use mods without a suitable database. These tools will create an own database automatically which can be saved as a language file and used afterwars.
As these tools have an early and dirty development code, I have to revise and optimize them before being able to release them.
Acknowledgments
Development of this database and its tools was inspired by X2-Illuminatus Hephaistos Corp. Station building service. Also the source code of the Factory Complex Constructor by -Dusty- was a big help in solving problems with the collision detection. So I say thank you to both of them.
Download
Database for X³:TC-factories (Alpha.2)