Mandalorian Armor Appearance Color Customization

Player submitted code/scripts.
jasonh
Light Jedi
<font color=#AAFF40>Light Jedi</font>
Posts: 541
Joined: Fri Dec 26, 2014 8:32 pm

Unread post

Please excuse any errors (I'm a noob at this) and constructive criticism appreciated.

Following changes allow color customization for mandalorian armor pieces. Code was created using Composite and SE Goggles .lua files as a template for enhanced SUI and options, based on http://www.swgemu.com/forums/showthread.php?t=142206.

Please note:
1) This will also add a second SUI option for composite armor that appears to have little/no effect on appearance.
2) The SUI options "Color Plates" and "Color Trim" may be titled more appropriately (i.e. less specifically) display actual changes to both affected armor types.
3) Belt appears to have less color options (more testing may prove it uses a different palette, such as a clothing palette) so recommend omitting belt pending further investigation.
4) Tested using vanilla SWGEmu tre files. Awakening files may be slightly different.

Each mandalorian armor piece .lua (bin/scripts/object/tangible/wearables/armor/mandalorian) would require the following code added.

Following line 45:

Code: Select all

templateType = ARMOROBJECT,
for each desired piece, add:

Code: Select all

objectMenuComponent = {"cpp", "ArmorObjectMenuComponent"}, 

In src/server/zone/objects/tangible/components/ArmorObjectMenuComponent.cpp, replace line 46:

Code: Select all

String text = "Color Change";
menuResponse->addRadialMenuItem(81, 3, text);
with:

Code: Select all

String text = "Color Trim"; //consider changing SUI text
menuResponse->addRadialMenuItem(81, 3, text);
String text2 = "Color Plates"; //to less specific language, i.e. Color Change 1/2
menuResponse->addRadialMenuItem(82, 3, text2);
and replace line (original line 54):

Code: Select all

if (selectedID == 81) {
with line:

Code: Select all

 if (selectedID == 81 || selectedID == 82) {
and replace line (original 94, under comment //The Sui Box):

Code: Select all

cbox->setColorPalette(variables.elementAt(1).getKey());
with lines:

Code: Select all

if (selectedID == 81) {
cbox->setColorPalette(variables.elementAt(1).getKey() );
} else {
cbox->setColorPalette(variables.elementAt(0).getKey() );
}
Thanks for taking a look, and if it's easier I'd be happy to attach files. Again, constructive criticism appreciated.
Dropoff Vendor:
463 -5910 Corellia
Pwntera
Sr. Member
Sr. Member
Posts: 719
Joined: Sat Nov 15, 2014 1:51 pm

Unread post

As a Mandalorian Armor owner I'm all for this happening. While in pre-CU and CU mando armor was randomly colored I feel that this server doesn't have to follow that 100% (and clearly isn't on a lot of aspects). Adding the custom color palette option would be the perfect touch to go with the enhanced stats that have been added to the Mandalorian Armor already (we really love the new LS resist).

My question would be does Mandalorian Armor have a unique color palette or does it use the same colors that we see on Composite Armor?
Sam's Club: /way 791 -5140 Coronet, Corellia
User avatar
BigQEd
Founder
<b>Founder</b>
Posts: 2088
Joined: Sat Sep 06, 2014 6:40 am

Unread post

It's actually something we are considering. Would be nice to be able to adjust Mando armor after working so hard to get it.
BigQEd
Retired Founder of SWG Awakening
My posts do not reflect the current views or opinions of the Awakening staff team.
Rules & Policies | ToS | Play Now | Awakening Discord | Events
User avatar
commotion
Force Sensitive
<font color=#BFFFFF>Force Sensitive</font>
Posts: 72
Joined: Sun Dec 28, 2014 9:42 pm

Unread post

Awesome!
Image
Drop off Vendor Location - Mon Cala, Corellia 210, -2860