[MOD] Faction Logos --» now for all buyable L/XL Ships

The place to discuss scripting and game modifications for X Rebirth.

Moderators: Moderators for English X Forum, Scripting / Modding Moderators

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

[MOD] Faction Logos --» now for all buyable L/XL Ships

Post by UniTrader » Sun, 17. Aug 14, 20:55

This Extension adds Faction Logos on Ship Hulls to get more Atmosphere in the Game without resorting to Atmosphere Transporters (sorry Gazz :P )

Features:
=> All buyable L and XL Ships display their respective Faction Logo on the Ship Hull.
=> This Faction Logo is also shown on the Floor in the Docking Platform on all L and XL Ships - so whereever you are docked you immediately know & feel whom this Ship belongs to Image
=> Supports Litauens Capship Bridges Image
=> Additionally selectable Player Logos were added in a seperate Extension - UTPlayerLogos:
--> 15 selectable Logos for Player Ships. Simply talk with the Engineer on the Skunk to set a global default Logo anyone will fall back to if no other one is found and/or a Personal Logo specific to the Player/Skunk Squad (and its subordinates, ofc ^^)
--> Alternatively you can set the Logo per Ship by talking with the respective Engineer ;) (or per squad, see next)
--> Hierarchies are full supported without additional actions - the technician will use the most specific Logo he can find (his own setting > Commander Ship > the Commanders Commander > …… etc… …… > global default Logo )
--> Additionally you can easily exchange these Logos and the Player Faction Icon on the HUD with your own by replacing the related Files in UTPlayerLogos/Player Logos Image

Currently supported Game Version is 2.5 RC2 (or later, as soon as i update) - Version 2.2 is not supported.

Download-Link
Here some Example Screenshots
(there is also a User Gallery at the bottom of this Post Image )

Installation: Extract the Archive into the Extensions-Folder, as usual Image

No existing Ship should have Logos after Update & Installation, but that can easily be fixed by docking at them if you want Image Newly Spawned Ships or all Ships in a new Game have Logos from the beginning Image

Deinstallation:
Deactivate and/or remove mod - it removes itself from Save while loading Image

Known Problems:
=> This Extension breaks the Upgrade System of the L and XL Ships. These Ships will be delivered always fully equipped - the Building Ressources have been updated accordingly. A selection possibility to not install certain or all Upgrades/surface Elements is no longer existent.
=> In the current Game Version 2.2 is a CTD when building/Upgrading a Ship via Script/MD. For the Vanilla-Game it should be fixed, but if any Extension tries to build a Ship or Upgrade it the Game will crash. therefore no Support for this Game Version (although it should work Image )

Legal Note: i will not be responsible if someone messes aorund with the customizeable Logos because i have no way to restrict what users might put in there.


=============================
========= USER GALLERY =========
=============================
Vim Razz wrote:It's up! Now the galaxy is DOOMED!!!!!!!!!!! :D
Tamina wrote:I like it very much! Splendid! :D
Out of my way Vim Razz!!! :P
Image
Image Image Image
NZ-Wanderer wrote:Done my very first Logo :)

http://steamcommunity.com/sharedfiles/f ... =317650324
Hoshinator wrote:Greetings UniTrader,

many thanks for your great mod! Gives the game a special atmosphere. I tagged my starting plot lyranea with my company logo and it looks great!

But the best part ist the GUI logo in my skunk-display, love it!

Here is a link:
http://steamcommunity.com/sharedfiles/f ... =321684265

Dragon Industries will rock the galaxy! :D

regards,
Hoshinator


All rights of the original logo belong to Bethesda Softworks, I just modified it for my own purpose (just to be on the save side) :roll:
Last edited by UniTrader on Fri, 3. Oct 14, 16:22, edited 25 times in total.
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

User avatar
YorrickVander
Posts: 2672
Joined: Tue, 29. Oct 13, 22:59

Post by YorrickVander » Sun, 17. Aug 14, 21:12

My first reaction would be to check for a typo that's looking for turret_small_mg.xml (the component file) instead of turret_small_mg_macro.xml
X Rebirth - A Sirius Cybernetics Corporation Product

Split irritate visiting pilot with strange vocal patterns.

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Sun, 17. Aug 14, 21:27

YorrickVander wrote:My first reaction would be to check for a typo that's looking for turret_small_mg.xml (the component file) instead of turret_small_mg_macro.xml
you couldnt be more wrong because i never used something even slightly similiar in my files. thats the weird thing.

here basically what i did:
-> added 25 new Components, Macros and meshes (and some new /re-used textures) which contain the Faction Logos to be placed on the Ship Hulls
-> modified some ships to have multimacro upgrades (the aforementoined Logos)
-> added and placed connections for those Logos on these Ships (3 or 4 per Ship)
-> modified the engineer scripts to execute the lib.set.faction.logo as first action
-> and this Script just removes all previous Logos and then adds the one which fits to the owner faction of the Object and then returns (without loops or waits)

nowhere ins these files a turret or gun is mentoined or refered..
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

User avatar
YorrickVander
Posts: 2672
Joined: Tue, 29. Oct 13, 22:59

Post by YorrickVander » Sun, 17. Aug 14, 21:32

Hmm interesting bug indeed. From experiments with the drostan macro I've also seen CTD from macro errors but as I don't have source reference for this exact issue I'll have to just wish you luck :)
X Rebirth - A Sirius Cybernetics Corporation Product

Split irritate visiting pilot with strange vocal patterns.

BlackRain
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 5029
Joined: Mon, 15. Dec 03, 19:53

Post by BlackRain » Mon, 18. Aug 14, 02:46

Yes, macro issues absolutely cause CTD's. A wrong macro reference or error in a macro will cause ctds. It could very well be macro related.

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Mon, 18. Aug 14, 05:30

Search "turret_small_mg" (0 hits in 0 files)

for a search in my whole extension. if it were something this simple i wouldnt open a topic for this... (and no, my extension does not remove or replace anything, it is just adding stuff)

and @Yorrick there is a DL Link for the whole thing in the 1st Post ;)

EDIT: here what my extension does on the example of a single Ship & Logo (they are almost identical with with each other):

Facttion Logo component & macro:

Code: Select all

<?xml version="1.0"?>
<components  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://utnas/~unitrader/XRebirthxsds/component.xsd" >
	<component name="markings_logos_faction_player_40x40m">
		<source geometry="\Extensions\UTFactionLogos\assets\markings\logos\faction_player\data\40m" />
		<connections>
			<connection name="Connection01" tags="part">
				<parts>
					<part name="part_main">
						<size>
							<max x="1" y="1" z="0" />
							<center x="0" y="-4.76837e-007" z="0" />
						</size>
						<lods>
							<lod index="0">
								<materials>
									<material id="1" ref="logos.faction_player" />
								</materials>
							</lod>
						</lods>
					</part>
				</parts>
				<offset>
					<position x="-0.000000" y="0.000000" z="0.000000" />
				</offset>
			</connection>
      <connection name="connection_faction_logo" tags="component faction_logo_40m" optional="0" />
		</connections>
	</component>
  
</components>

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<!--Exported by: Simon (192.168.3.115) at 14.11.2012_12-20-10-->
<macros>
  <macro name="markings_logos_faction_player_40x40m_macro"   class="adsign">
    <component ref="markings_logos_faction_player_40x40m" />
    <properties>
      <effects>
        <explosion ref="explosion_adsign_01" />
      </effects>
      <sounds>
        <ambient ref="adsign_ambient_l" />
      </sounds>
    </properties>
  </macro>
</macros>
the mesh used by them is a simple textured square (40x40m) and works fine InGame

changes to the Ships, using the Lyranea as example:
Component ( units_size_xl_cs_omicron_ship_01.xml )

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<diff>
  <add sel='//connections' >
    <connection name="connection_faction_logo_01" tags="faction_logo_40m">
      <offset>
        <position x="-88" y="-133" z="540" />
        <quaternion qx="0" qy="0.7071067811865475" qz="0" qw="0.7071067811865475"  />
      </offset>
    </connection>
    <connection name="connection_faction_logo_02" tags="faction_logo_40m">
      <offset>
        <position x="88" y="-133" z="540" />
        <quaternion qx="0" qy="0.7071067811865475" qz="0" qw="-0.7071067811865475" />
      </offset>
    </connection>
    <connection name="connection_faction_logo_03" tags="faction_logo_40m">
      <offset>
        <position x="100" y="57" z="-1030" />
        <quaternion qx="0.7071067811865475" qy="0" qz="0" qw="0.7071067811865475" />
      </offset>
    </connection>
    <connection name="connection_faction_logo_04" tags="faction_logo_40m">
      <offset>
        <position x="-100" y="57" z="-1030" />
        <quaternion qx="0.7071067811865475" qy="0" qz="0" qw="0.7071067811865475" />
      </offset>
    </connection>
  </add>
</diff>
Macro ( units_size_xl_cs_omicron_ship_01_macro.xml ):

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<diff>
  <add sel='//properties' >
      <upgrades multimacro="1">
        <upgrade upgrade="markings_logos_faction_ae_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_aquarius_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_argon_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_beryll_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_canteran_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_chow_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_dispossed_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_enemy_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_fijiargnu_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_fp_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_friend_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_heartofalbion_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_jsdd_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_ledda_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_neutral_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_no_limits_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_ownerless_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_player_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_pmc_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_red_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_reivers_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_ryak_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_standard_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_wf_40x40m_macro" tags="faction_logo_40m" />
        <upgrade upgrade="markings_logos_faction_xenonmatrix_40x40m_macro" tags="faction_logo_40m" />
      </upgrades>
  </add>
  <add sel="//macro[@class='ship_xl']/connections" >
      <connection ref="connection_faction_logo_01" />
      <connection ref="connection_faction_logo_02" />
      <connection ref="connection_faction_logo_03" />
      <connection ref="connection_faction_logo_04" />
<!--      <connection ref="connection_faction_logo_05" />
      <connection ref="connection_faction_logo_06" />-->
  </add>
</diff>
the other macro and component diff files are almost indentical, in fact i have just made symlinks here for all L-Ship Macros and most of the L Ships Components for easier maintinence because the only difference between them are the coordinates of the facrion logo Connections.

InGame everything works fine, except for those "random" Crashes probably on Ship Construction by NPCs
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

User avatar
YorrickVander
Posts: 2672
Joined: Tue, 29. Oct 13, 22:59

Post by YorrickVander » Mon, 18. Aug 14, 20:37

I'm coming at this backwards (now I found that funny orange text that magically transports your code onto my hd) but it appears trade.shipyard.xml is causing (possibly indirectly) the crash.

Code: Select all

<debug_text text="'Create build plan!'" filter="error" chance ="100"/>
              <create_build_plan macro="$selected_macro" buildplan="$build_plan">
                <buildplan>
                  <buildsequence sequence="''" stage="0"/>
                </buildplan>
                <upgradeplan>
                  <!-- See defaults.xml for valid upgrades -->
                  <upgradeentry upgrade="'turret_small_sg'" level="1"/>
                  <upgradeentry upgrade="'turret_small_mg'" level="1"/>
                  <upgradeentry upgrade="'turret_medium_pe'" level="1"/>
                  <upgradeentry upgrade="'turret_medium_lb'" level="1"/>
                  <upgradeentry upgrade="'turret_missile_df'" level="1"/>
                  <upgradeentry upgrade="'turret_missile_sm'" level="1"/>
                  <upgradeentry upgrade="'shieldgenerator'" level="1"/>
                </upgradeplan>
              </create_build_plan>
              <debug_text text="'Created build plan!'" filter="error" chance ="100"/>

              <debug_text text="'Constructing ship!'" filter="error" chance ="100"/>
              <construct_ship object="this.station" buildmodule="$buildmodule" macro="$selected_macro" faction="this.station.owner" buildplan="$build_plan" updatebuild="true"/>
              <debug_text text="'Construction command returned!'" filter="error" chance ="100"/>
Some ships build fine following through the text of debug.log after the CTD. The crash happens when <construct_ship is called. Running test again for what ship is built when the game goes *boom*...

BTW do you see this error line? It shows for me in 2.20 but the logos display fine on rahanas' at least on game start

Code: Select all

[General] ======================================
[=ERROR=] Cannot match path '//dataset[@class="destructible"]/properties/upgrades/upgrade[@upgrade="efficiency"]/@tags' in patch file 'extensions\UTFactionLogos\libraries\renderparam_library'. Skipping node.
[General] ======================================

EDIT :

Confirming it's building logo bearing ships that causes crash, hermod + sequana were fine, rahanas (energy) killed game.

EDIT 2 :

Has renderparam_library.xml changed a lot recently? the reference made to it is wildly different to anything the file contains for 2.20.
X Rebirth - A Sirius Cybernetics Corporation Product

Split irritate visiting pilot with strange vocal patterns.

Ginger470
Posts: 158
Joined: Sun, 20. Jun 04, 03:24

Post by Ginger470 » Tue, 19. Aug 14, 01:39

@UniTrader

Don't mean to derail this thread, but could I, uh, 'borrow' that 40x40 plane model for something I'm working on? Been looking for a flat 2d plane for ages.

Also, would it be possible to explain how to resize the plane (or point me in the direction of a tutorial)?

Many, many thanks :)

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Tue, 19. Aug 14, 05:56

YorrickVander wrote:======================================
[=ERROR=] Cannot match path '//dataset[@class="destructible"]/properties/upgrades/upgrade[@upgrade="efficiency"]/@tags' in patch file 'extensions\UTFactionLogos\libraries\renderparam_library'. Skipping node.
[General] ======================================[/code]

………
EDIT 2 :

Has renderparam_library.xml changed a lot recently? the reference made to it is wildly different to anything the file contains for 2.20.
i experimented a lot with that file and the defaults.xml at last because those where the only files i found the "turret_small_mg" (including the " ) - could be that i left someting invalid there when making the package.. my last attempts were more try&error anyway

and thanks for the new lead, i think i now know what the Game expects there :) will try out when i am at home today evening :)


@Ginger470 as long as you dont steal my next extension of this :P because there is far more which can be done with mulimacro upgrades (by putting them on top of each other and arrange them like Letters ^^ )

and for resizeing: i got a 2x2m plane from arc_ initially which i converted to a dae file using his tools and changed the coordinates there (that files are also xml ^^) and converted it back ;) (1 inGame-meter is 1 distance unit in there ;) and i just noticed my plane is 80x80m big, not 40x40.. because it goes from -40 to 40)
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

Ginger470
Posts: 158
Joined: Sun, 20. Jun 04, 03:24

Post by Ginger470 » Tue, 19. Aug 14, 19:02

@UniTrader;

Thanks! So you know where this is headed, I'm looking at building a HUD system, so these planes would be used to float in front of the cockpit glass to draw a bar-meter gauge system kinda thing. Then, using effects.xml, I can turn on/off bar cells (or warning lights etc). I've just been held up cause I couldn't find a flat plane -- been using the poster model from the skunk rear :) May be similar to what you're doing (technically) but it's for an entirely different purpose, so hopefully I'm not treading on your toes :)

Thanks again for the input :)

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Fri, 22. Aug 14, 23:06

UPDATE:

I have partially solved the CTD Issue ;) the Game wont Crash anymore, but it may have consequences for the Economy, i couldnt test it yet:

The problem with the CTD was that i use Dynamic Extensions for Ships (or multimacro upgrades as they are called in the Game Files), but those seem not to be compatible with the 0-100%-Upgrades used on all Ships except the Skunk when setting up the construction. I have removed the Upgrade Setting in the NPC build script and A) it didnt crash anymore and B) all Shipps are still built completely equipped BUT C) i am not really sure if the Wares are consumed during construction, so it currently may have an impact on the economy.. Same case with the Player Ships: the Dialogue to equip Shields and Turrets is empty, but the Ships are built with all available Upgrades, so you wont have any disadvantages ;)


Of course i will look into how to resolve this, but i think thats something where EGO has to act..

DL Link didnt change and is to be found in the first Post for anyone interested ;)
1st Post will be re-done at a later Date ;)
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Thu, 4. Sep 14, 19:35

Crash is fixed with Beta 2.5, although i still have to test out how i i can manage it to still be able to use as much upgrade functionality as possible (still seems partially broken, but at least it does not crash anymore)

and a Question here: is someone currently actively using this Extension?
i am asking because the next Version will not be savegame-compatible with the current one if no patch is applied (i want to clean up some things in the naming patterm and improve/rewrite some parts using the expierience i gained while messing around with this :D) - if someone currently uses this i will make a savegame-patch, if not i will use the time for other stuff™

Additionally i announce the following improvements in the next and first "productive" Version (although Work is ongoing):

-> Extension is now compatible with ships that use parts of the existing Rahnas/Sul-Class Ship Line instead of being applied per-ship (eg. compatible with actual modular Rahanas :D - if someone should make them) - same applies to all other Ships i add to this Extension in the future: their parts will be marked, not the Ship as a whole ;)

-> there will be Faction Logos in Ship/Station Interiors (for now just the Repair-Style Platform; more will be added when i find good Spots)

-> up to 5 diffrent Logos for the Player Faction, simply exchangeable by replacing 5 files made specifically for this purpose ;) - just talk with your Engineers and they will grab a brush ;) :D (this is a seperate Extension to allow others implementing a other/better/diffrent interface for that; i am not really good in making these)
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

User avatar
NZ-Wanderer
Posts: 1464
Joined: Thu, 5. Aug 04, 01:57

Post by NZ-Wanderer » Thu, 4. Sep 14, 22:44

This sounds great, will have to check it out at some stage :)

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13817
Joined: Sun, 20. Nov 05, 23:45

Post by UniTrader » Sun, 7. Sep 14, 23:54

ok, i have experimented this weekend with the upgrade system and came to the following conclusion:

it is not possible to combine this Extension (or better: multimacro upgrades) with 0-100% Ship Upgrades. Although i can add those upgrades to work somehow, but if a ship has eg 15 Shields of 3 diffrent types i can only make these 3 diffrent types appear as 3 diffrent entries in the upgrade list (which wouldnt be a problem), but for 15 possible Slots each (which is imo a problem since it throws out the balancing) - or i remove the Upgrade possibilities altogether and you just get fully equipped Ships (which i think most of you do anyway - right? )
Drones wont be affected by this, it is just about turrets and Shields ;)
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

Vim Razz
Posts: 1797
Joined: Tue, 2. Nov 10, 03:20

Post by Vim Razz » Mon, 8. Sep 14, 07:50

whaa...? and loose the fun of clicking "change" and manually moving the slider over (no home/end, natch) and over and over again with every single individual ship.........?

I dunno.. that sounds like a pretty hard sell...... :P



I've been watching this all with great interest, and am looking forward to seeing what the next version holds.

Post Reply

Return to “X Rebirth - Scripts and Modding”