Custom weapon won't charge. [Solved]

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
commanderawesome
Field Commander
Field Commander
Posts: 971
Joined: Tue Aug 13, 2013 11:58 pm
Projects :: Skin Changer - Warfront - Other stuff
Games I'm Playing :: SWBF SWTOR KotOR EaW
xbox live or psn: AaTc_CmdrAwesome
Location: The Universe

Custom weapon won't charge. [Solved]

Post by commanderawesome »

Am I doing something wrong? It works perfectly fine except it doesn't charge.

Here's the odf:
Hidden/Spoiler:
[code][WeaponClass]
ClassParent = "com_weap_inf_rifle"
GeometryName = "rep_weap_inf_rifle.msh"

[Properties]
GeometryName = "rep_weap_inf_rifle"
HighResGeometry = "rep_1st_weap_inf_rifle"
OrdnanceName = "rep_weap_inf_rifle_ord"
FirePointName = "hp_fire"

//***********************************************
//*********** WEAPON PERFORMANCE VALUES *********
//***********************************************

RoundsPerClip = "42"
ReloadTime = "2.0"
ShotDelay = "0.6"
TriggerSingle = "1"

SalvoCount = "3"
ShotsPerSalvo = "1"
SalvoDelay = "0.2"
InitialSalvoDelay = "0.0"
SalvoTime = "0.0"

NextCharge = 0.33

ShotsPerSalvo = 1
OrdnanceName = "rep_weap_inf_heavyrifle_ord_med"

NextCharge = 0.95

ShotsPerSalvo = 1
OrdnanceName = "rep_weap_inf_heavyrifle_ord_high"

//******************************************************
//*************** SOUND ****************
//******************************************************

MuzzleFlash = "small_muzzle_flash"
FlashColor = "80 80 255 255"
FlashLength = 0.025
FlashColor = "100 100 255 255"
FlashLength = 0.025
FlashLightColor = "220 220 255 175"
FlashLightRadius = "2.0"
FlashLightDuration = "0.25"
Discharge = "small_smoke_effect"


FireSound = "rep_weap_inf_rifle_fire"
ReloadSound = "com_weap_inf_reload_med"
ChangeModeSound = "com_weap_inf_equip_med"
FireEmptySound = "com_weap_inf_ammo_empty"
WeaponChangeSound = "com_weap_inf_equip_med"
JumpSound = "com_weap_inf_rifle_mvt_jump"
LandSound = "com_weap_inf_rifle_mvt_land"
RollSound = "com_weap_inf_rifle_mvt_roll"
//ProneSound = "com_weap_inf_rifle_mvt_lie"
SquatSound = "com_weap_inf_rifle_mvt_squat"
//StandSound = "com_weap_inf_rifle_mvt_getup"[/code]
And those of it's ammo:
Regular:
Hidden/Spoiler:
[code][OrdnanceClass]
ClassParent = "com_weap_inf_rifle_ord"

[Properties]

LaserTexture = "com_sfx_laser_blue"
LaserGlowColor = "92 136 250 100"
LightColor = "92 136 250 100"

Velocity = "150.0"
MaxDamage = "40.0"[/code]
Medium:
Hidden/Spoiler:
[code][OrdnanceClass]
ClassParent = "com_weap_inf_rifle_ord"

[Properties]

LaserTexture = "com_sfx_laser_blue"
LaserGlowColor = "92 136 250 100"
LightColor = "92 136 250 100"


MaxDamage = "105.0"[/code]
Heavy:
Hidden/Spoiler:
[code][OrdnanceClass]
ClassParent = "com_weap_inf_rifle_ord"

[Properties]

LaserTexture = "com_sfx_laser_blue"
LaserGlowColor = "92 136 250 100"
LightColor = "92 136 250 100"


MaxDamage = "315.0"

[/code]
Last edited by commanderawesome on Thu Jul 03, 2014 3:59 pm, edited 1 time in total.
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Custom weapon won't charge.

Post by AQT »

You need to specify a non-negative value for the MaxPressedTime parameter in the main ODF. It's for how long you hold the fire button until it fully charges.
User avatar
commanderawesome
Field Commander
Field Commander
Posts: 971
Joined: Tue Aug 13, 2013 11:58 pm
Projects :: Skin Changer - Warfront - Other stuff
Games I'm Playing :: SWBF SWTOR KotOR EaW
xbox live or psn: AaTc_CmdrAwesome
Location: The Universe

Re: Custom weapon won't charge.

Post by commanderawesome »

Ok, now it charges, but the shots per salvo doesn't change.
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Custom weapon won't charge.

Post by AQT »

That's because you haven't changed them.
User avatar
commanderawesome
Field Commander
Field Commander
Posts: 971
Joined: Tue Aug 13, 2013 11:58 pm
Projects :: Skin Changer - Warfront - Other stuff
Games I'm Playing :: SWBF SWTOR KotOR EaW
xbox live or psn: AaTc_CmdrAwesome
Location: The Universe

Re: Custom weapon won't charge.

Post by commanderawesome »

NextCharge = 0.33

ShotsPerSalvo = 1
OrdnanceName = "rep_weap_inf_heavyrifle_ord_med"

NextCharge = 0.95

ShotsPerSalvo = 1
OrdnanceName = "rep_weap_inf_heavyrifle_ord_high"
That was in the original odf. I want a 3-shot burst when firing normally, but one shot when charged.
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Custom weapon won't charge.

Post by AQT »

commanderawesome wrote:SalvoCount = "3"
ShotsPerSalvo = "1"
Then change the SalvoCount instead. Setting the ShotsPerSalvo at 1 again won't do anything...
User avatar
commanderawesome
Field Commander
Field Commander
Posts: 971
Joined: Tue Aug 13, 2013 11:58 pm
Projects :: Skin Changer - Warfront - Other stuff
Games I'm Playing :: SWBF SWTOR KotOR EaW
xbox live or psn: AaTc_CmdrAwesome
Location: The Universe

Re: Custom weapon won't charge.

Post by commanderawesome »

It works! Thanks! :)
Post Reply