Problem with Jedi light saber....

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
XXXNewbie666XXX

Problem with Jedi light saber....

Post by XXXNewbie666XXX »

This is not a problem with the textures or something, is about how i can add a Light saber to a ordinary trooper.....

I see levels that, for example, the Jettrooper has a light saber, and the Magnaguard a Double light saber....

How i can do it???.....
somen00b

Post by somen00b »

First let me caution you that if your unit has a lightsaber it can't have any other primary weapons. Also, primary weapons and secondary weapons can't take eachother's places without some editing.
If you still want to forage ahead read on :D

First you need to put an animation line in your unit's ODF like this:
AnimationName = "mace"
if you want to use Mace Winu's moves if you want to use a different jedi's moves, enter the AnimationName in that jedi's odf file instead of "mace"

then copy these lines from the jedi's odf to your unit's odf.
WEAPONSECTION = 1
WeaponName1 = "rep_weap_lightsaber"
WeaponAmmo1 = 0
and change "WeaponName1" to "WeaponName" and "WeaponAmmo1" to "WeaponAmmo" ("WeaponName1" will difer depending on the jedi)
You will notice that you unit already has those lines, delete the old lines.

notes:
1. this assumes that you want to user the moves of a jedi on the same side as the unit, I will add how to use jedi's moves from a different side if you want

2. this theoretically works for darth maul, I've never tried it

3. darth vader requires one extra step

4. This is from memory

bonus stuff,
here are some lines to make your unit more jedi like, add these to your unit's odf,
jedi energy bar:
EnergyBar = 100.0 // Max energy
EnergyRestore = 15.0 // energy regained per second if moving
EnergyRestoreIdle = 25.0 // energy regained per second if not
EnergyDrainSprint = 15.0 // energy spent per second of sprinting
EnergyMinSprint = 20.0 // min energy to start sprinting
EnergyCostJump = 0.0 // energy cost to jump
EnergyCostRoll = 25.0 // energy cost to roll
jedi movement values:
// Movement defaults
// These are values for an average class - some soldiers will override these
MaxSpeed = 9.0 // base forward speed
MaxStrafeSpeed = 6.6 // base right/left speed
MaxTurnSpeed = 6.0 // base turn speed
JumpHeight = 3.5 // base jump height in meters
RecoverFromTumble = "1"

BlurEffect = "0.8" //motion blur effect for force run

// Speed multipliers for various actions
JumpForwardSpeedFactor = 1.3 // boost forward part of velocity by this factor when jumping
JumpStrafeSpeedFactor = 1.0 // boost side/backward part of velocity by this factor when jumping
RollSpeedFactor = 1.5 // in forward arc, boost speed by this factor when rolling

// Apparently contant for all or most classes:
Acceleration = 70.0 // accelerate to full run in about 7/70 = 0.1 seconds
SprintAccelerateTime = 0.35 // accelerate from run to sprint in this time

ControlSpeed = "stand 1.00 1.00 1.00"
ControlSpeed = "crouch 0.70 0.60 1.00"
ControlSpeed = "prone 0.30 0.20 0.50"
ControlSpeed = "sprint 2.50 0.50 0.50"
ControlSpeed = "jet 1.50 1.25 1.25"
ControlSpeed = "jump 0.10 0.10 0.60"
ControlSpeed = "roll 0.02 0.02 0.35"
ControlSpeed = "tumble 0.00 0.00 0.10"
force jump:
JetJump = "10.0" //The initial jump-push given when enabling the jet
JetPush = "0.0" //The constant push given while the jet is enabled (20 is gravity)
JetAcceleration = "10.0" // for characters with jet jump, use this acceleration for in air control
JetEffect = ""
JetFuelRechargeRate = "0.0" //Additional fuel per second (fuel is 0 to 1)
JetFuelCost = "0.0" //Cost per second when hovering (only used for jet-hovers)(fuel is 0 to 1)
JetFuelInitialCost = "0.0" //4initial cost when jet jumping(fuel is 0 to 1)
JetFuelMinBorder = "0.0" //minimum fuel to perform a jet jump(fuel is 0 to 1)
JetShowHud = 0
JetEnergyDrain = 40.0

CollisionScale = "0.0 0.0 0.0" // don't take damage from collisions
hope this helps!
XXXNewbie666XXX

Post by XXXNewbie666XXX »

I have do this but my game crashes, see my odf:

[GameObjectClass]
ClassParent = "cis_inf_default"


[Properties]

AnimationName = "maul"

PointsToUnlock = 8

ExplosionName = "cis_inf_droid_exp"
UnitType = "support"

WEAPONSECTION = 1
WeaponName = "cis_weap_doublesaber"
WeaponAmmo = 0


VOUnitType = 093

// the foot height where footstep sounds are played
MinFootHeight = 0.3

VOSound = "cis1_inf_pc_com_hostile SpottedVO"
VOSound = "cis1_inf_pc_com_bacta NeedMedicVO"
VOSound = "cis1_inf_pc_com_mechanic NeedRepairVO"
VOSound = "cis1_inf_pc_com_ammo NeedAmmoVO"
VOSound = "cis1_inf_pc_com_transport NeedPickupVO"
VOSound = "cis1_inf_pc_com_backup NeedBackupVO"
VOSound = "cis1_inf_pc_com_clear_area AttackPositionVO"
VOSound = "cis1_inf_pc_com_defend DefendPositionVO"

VOSound = "cis1_inf_pc_com_hostile_inVehicle SpottedVO +InVehicle"
VOSound = "cis1_inf_pc_com_bacta_inVehicle NeedMedicVO +InVehicle"
VOSound = "cis1_inf_pc_com_mechanic_inVehicle NeedRepairVO +InVehicle"
VOSound = "cis1_inf_pc_com_ammo_inVehicle NeedAmmoVO +InVehicle"
VOSound = "cis1_inf_pc_com_transport_inVehicle NeedPickupVO +InVehicle"
VOSound = "cis1_inf_pc_com_backup_inVehicle NeedBackupVO +InVehicle"
VOSound = "cis1_inf_pc_com_clear_area_inVehicle AttackPositionVO +InVehicle"
VOSound = "cis1_inf_pc_com_defend_inVehicle DefendPositionVO +InVehicle"

Is something wrong???
Dabrowski

Post by Dabrowski »

First let me caution you that if your unit has a lightsaber it can't have any other primary weapons. Also, primary weapons and secondary weapons can't take eachother's places without some editing.
Actually... if you put the gun as the first primary and the saber as the second primary, then you can have both :)
somen00b

Post by somen00b »

Droids have custom skeletons, that is the extra step for darth vader. That might be why.


To rule out map and new unit errors, it is best to make a custom side first, follow this turtorial with some changes below to do it:
http://www.gametoast.com/index.php?name ... +bat+sides
the changes are:

1. skip step three (you could skip it anyway)

2. for step five, add the animation lines you used to "cis_inf_officer.odf" and cis_inf_officer_hunt.odf" then add the weapon lines to "cis_inf_default_officer.odf" (in the futrue any side editing goes here)

3. skip steps 6 and 7

4. After step 9, make a copy of the "SIDE" folder stored at a "Star Wars Battlefront II\GameData\DATA\_LVL_PC" this way you have a backup of your old sides. (you only have to do this once)

5. copy the files cis.lvl and cisshell.lvl at "Star Wars Battlefront II\GameData\addon\ABC\data\_LVL_PC\SIDE" (where ABC is your mod directory) and paste them in "Star Wars Battlefront II\GameData\DATA\_LVL_PC\SIDE"

this is basically how to create a custom side mod

if you have the CD version of the game, copy the "BF2_modtools" executable to "Star Wars Battlefront II\GameData" and run it, if not, run the game. Eather way, start any shipped map with the magnaguard and if see if it crashes (if you have the DVD version of the game, don't dispair you can still get error output)

if it crashes and you were running BF2_modtools look for a text document that is named "BFront2" and post what it says,

At best the other weapons probably won't fire (trigger does nothing) I'll tell you how to fix this later
somen00b

Post by somen00b »

Dabrowski wrote:
First let me caution you that if your unit has a lightsaber it can't have any other primary weapons. Also, primary weapons and secondary weapons can't take eachother's places without some editing.
Actually... if you put the gun as the first primary and the saber as the second primary, then you can have both :)
I thought that screwed with the animations
t551
General
General
Posts: 791
Joined: Sat Jul 16, 2005 3:23 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set

Post by t551 »

It can, if you're using a non-standard skeleton such as the wookie, but for the default trooper skeleton, it'll be fine.
XXXNewbie666XXX

Post by XXXNewbie666XXX »

I think that will be more easy....

In my ODF is something wrong???? I want to know it....

I have the DVD version and try to run the BF2_modtools and nothing happends, i have the following message: "Insert disc1"

Ok with the droid si more hard to set as light saber, but with normal trooper??????
somen00b

Post by somen00b »

did it crash when you ran the normal game? please tell me.
If yes, read on. If no, tell me what happened, and read on anyway.

for debug output (error reporting) for the DVD version you can read this thread:
http://www.gametoast.com/index.php?name ... pic&t=5363

for XXX, put a default map in clone wars era ex: "kas2c_con"
if setting up batch files is hard for you (it was for me) add the rest of the second line after "BattlefrontII.exe" and the thridline to the target line of a shortcut to the server manager's "BattlefrontII.exe" after the quotes with no quotes
XXXNewbie666XXX

Post by XXXNewbie666XXX »

Yes my game crash during the normal game, i'm downloading the file of PC server....
Post Reply