Award Weapon Issue [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
Hill400
Private First Class
Posts: 81
Joined: Wed Jun 11, 2014 4:50 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: New England, USA

Award Weapon Issue [Solved]

Post by Hill400 »

Hello,
I've been having an issue that I think has to do with award weapons. I created a new side with a standard weapon but no award weapon, and when I try to switch the weapon the weapon the screen freezes (I have frenzy on legendary). I tried adding "ScoreForMedalsType = -1" and "MedalsTypeToUnlock = -1" (without out quotation marks) but it hasn't helped.

Here is the sides's code:
Hidden/Spoiler:
[code][GameObjectClass]
ClassParent = "rep_inf_default"


[Properties]
MaxHealth = 450.0

PointsToUnlock = 8

MaxSpeed = 5.9 // base forward speed
MaxStrafeSpeed = 4.8 // base right/left speed

WEAPONSECTION = 1
WeaponName = "rep_weap_inf_rifle"
WeaponAmmo = 6

WEAPONSECTION = 2
WeaponName = "rep_weap_inf_thermaldetonator"
WeaponAmmo = 4
WeaponChannel = 1

WEAPONSECTION = 3
WeaponName = "rep_weap_inf_detpack"
WeaponAmmo = 3
WeaponChannel = 1


VOUnitType = 121[/code]
and here's the weapon's code:
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"

ScoreForMedalsType = -1
MedalsTypeToUnlock = -1

//******************************************************
//*************** 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]
Thanks for anyone's help!
Last edited by Hill400 on Wed Nov 26, 2014 6:38 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: Award Weapon Issue

Post by AQT »

Remove all the medal related lines, and make sure your weapon ODF doesn't inherit from com_weap_inf_rifle.odf.
Hill400
Private First Class
Posts: 81
Joined: Wed Jun 11, 2014 4:50 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: New England, USA

Re: Award Weapon Issue

Post by Hill400 »

I removed all of the "medal related lines" and made it inherit from a copy of "com_weap_inf_rifle" without any medal references and the problem still persists. Should I make a new parent class from scratch?
jedimoose32
Field Commander
Field Commander
Posts: 938
Joined: Thu Jan 24, 2008 12:41 am
Projects :: Engineering Degree
Location: The Flatlands of Canada

Re: Award Weapon Issue

Post by jedimoose32 »

When you say you used ScoreForMedalsType and MedalsTypeToUnlock =-1, do you mean you put those in the unit's weapon odf, or in the parent odf? Personally my strategy for getting rid of award weapons is to make all of the common parents have a -1 value for these properties. Never have any problems with them.
JimmyAngler
High General
High General
Posts: 837
Joined: Mon Nov 04, 2013 10:37 am
Projects :: Battlefront Halation
Games I'm Playing :: SWBF 1-2-2015
xbox live or psn: none
Location: Area 51

Re: Award Weapon Issue

Post by JimmyAngler »

I had the same problem, BF2 doesn't like anything with the word "award" in its odf for some reason. I ended up changing it to elite or something like that.
jedimoose32
Field Commander
Field Commander
Posts: 938
Joined: Thu Jan 24, 2008 12:41 am
Projects :: Engineering Degree
Location: The Flatlands of Canada

Re: Award Weapon Issue

Post by jedimoose32 »

If what I said doesn't work then post your BFront2 error log. That's usually really helpful when it comes to solving weapon problems.
Hill400
Private First Class
Posts: 81
Joined: Wed Jun 11, 2014 4:50 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: New England, USA

Re: Award Weapon Issue

Post by Hill400 »

Thanks jedimoose, it worked. I was always editing the child class when I should have been editing the parent class.
Post Reply