How do i attach a jump pack/jet pack to a custom unit

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
Zapattack1234
Rebel Colonel
Rebel Colonel
Posts: 574
Joined: Mon Sep 24, 2012 6:44 pm
Projects :: The Wrecked Graveyard_Amongst the Ruins
Games I'm Playing :: SWBF 1 and 2
xbox live or psn: xbla:Rehmfire49
Location: Isla Nublar (Jurassic Park)

How do i attach a jump pack/jet pack to a custom unit

Post by Zapattack1234 »

Hi, i found a new unit i would like to use but i would like to know how to add a jump pack to my unit. can anyone help me? :?
User avatar
Nedarb7
Lieutenant General
Lieutenant General
Posts: 676
Joined: Sat Sep 22, 2012 3:41 pm

Re: How do i attach a jump pack/jet pack to a custom unit

Post by Nedarb7 »

You'll need these lines in the unit's default odf (odf name example rep_inf_default_trooper):

ControlSpeed = "jet 1.50 1.25 1.25"

JetJump = "5.0" //7 //The initial jump-push given when enabling the jet
JetPush = "8.0" //The constant push given while the jet is enabled (20 is gravity)
JetAcceleration = "30.0" //Acceleration while hovering.
JetEffect = ""
JetType = "hover"
JetFuelRechargeRate = "0.50" //Additional fuel per second (fuel is 0 to 1)
JetFuelCost = "0.01" //Cost per second when hovering (only used for jet-hovers)(fuel is 0 to 1)
JetFuelInitialCost = "0.25" //initial cost when jet jumping(fuel is 0 to 1)
JetFuelMinBorder = "0.24" //minimum fuel to perform a jet jump(fuel is 0 to 1)

In the line JetEffect I removed the jetpack effect (fire that comes out of it)
Add this into the quotation marks of that line to place the effect back in:
rep_sfx_jetpack

-EDIT-
Also if you don't want the unit to get hurt when it falls add this to the default odf (I think):
CollisionScale = "0.0 0.0 0.0"

For sound add this line to the default odf:
EngineSound = "rep_inf_Jetpack_engine_parameterized"
TurnOnSound = "rep_weap_jetpack_turnon"
TurnOffSound = "rep_weap_jetpack_turnoff"
TurnOffTime = 0.0
Last edited by Nedarb7 on Sun Nov 18, 2012 9:58 pm, edited 1 time in total.
User avatar
Zapattack1234
Rebel Colonel
Rebel Colonel
Posts: 574
Joined: Mon Sep 24, 2012 6:44 pm
Projects :: The Wrecked Graveyard_Amongst the Ruins
Games I'm Playing :: SWBF 1 and 2
xbox live or psn: xbla:Rehmfire49
Location: Isla Nublar (Jurassic Park)

Re: How do i attach a jump pack/jet pack to a custom unit

Post by Zapattack1234 »

thanks, also when trying to add the new unit to my map, i recieved this error with the custom skin i am trying to use:


ERROR[PC_texturemunge msh\jed_inf_jedi.tga]:Targa palette entry size 70 not currently supported.
ERROR[PC_texturemunge msh\jed_inf_jedi.tga]:Targa palette entry size 70 not currently supported.
[continuing]
2 Errors 0 Warnings

do u know how to fix this?
User avatar
Nedarb7
Lieutenant General
Lieutenant General
Posts: 676
Joined: Sat Sep 22, 2012 3:41 pm

Re: How do i attach a jump pack/jet pack to a custom unit

Post by Nedarb7 »

This is my guess, the texture size is 70x70, if so try re-sizing it to 512x512.
Just a guess though. :?
User avatar
Zapattack1234
Rebel Colonel
Rebel Colonel
Posts: 574
Joined: Mon Sep 24, 2012 6:44 pm
Projects :: The Wrecked Graveyard_Amongst the Ruins
Games I'm Playing :: SWBF 1 and 2
xbox live or psn: xbla:Rehmfire49
Location: Isla Nublar (Jurassic Park)

Re: How do i attach a jump pack/jet pack to a custom unit

Post by Zapattack1234 »

Im sorry, but how would one go about doing that? :?

EDIT:
apparently it is already that size, so it still doesnt work
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: How do i attach a jump pack/jet pack to a custom unit

Post by AceMastermind »

Open the image in a hex editor and copy the first 18 bytes of the file, then paste it here so I can compare it to a SWBF2 compatible tga file. We rarely see an error like this and i'm curious to see how the image was saved. The 18 byte header will give us the answer.

Similar posts:
forums/viewtopic.php?f=27&t=16914&p=291 ... ze#p291750
forums/viewtopic.php?f=27&t=13163&p=231 ... ze#p231037

EDIT
This is the header from Dragonum's rep_la_at.tga discussed in the first thread:

Code: Select all

00 00 0A 00 00 00 00 00 00 00 00 00 00 02 00 02 
18 00
^file size for this 512x512 image is 691 KB

This is the shipped rep_la_at.tga header:

Code: Select all

00 00 02 00 00 00 00 00 00 00 00 00 00 02 00 02 
18 00
^file size for this 512x512 image is 768 KB

The only difference other than file size is the third byte in Dragonum's image which is 0A in hex, but is 10 in decimal.
The third byte in the header represents the image type. According to the format specs, image type 10 is run-length encoded true-color.
'run-length encoded' means this image has been RLE compressed.
Normally this would throw a 'Targa type 10 not supported' error. :?

http://en.wikipedia.org/wiki/Truevision_TGA#Header
User avatar
Zapattack1234
Rebel Colonel
Rebel Colonel
Posts: 574
Joined: Mon Sep 24, 2012 6:44 pm
Projects :: The Wrecked Graveyard_Amongst the Ruins
Games I'm Playing :: SWBF 1 and 2
xbox live or psn: xbla:Rehmfire49
Location: Isla Nublar (Jurassic Park)

Re: How do i attach a jump pack/jet pack to a custom unit

Post by Zapattack1234 »

Ok thanks
Post Reply