Page 1 of 2

Award Weapons

Posted: Mon Nov 16, 2009 8:56 pm
by trainmaster611
Ok, so I understand the basics of assigning award weapons, but I don't totally grasp it and I need help with this.

What I'm looking to do is assign specific award weapons to certain primary weapons after a given accomplishment. For example, giving the award blaster rifle after 8 headshots with the primary blaster rifle. As far as awards go, I've really only been able to find these parameters (examples from the snipe rifle odfs)
Primary Weapon wrote:ScoreForMedalsType = 4
MedalsTypeToLock = 4
Award Weapon wrote:MedalsTypeToUnlock = 4
ScoreForMedalsType = 4
What exactly these do these parameters do and what do the values represent? And how could I manipulate these to give certain award weapons after certain accomplishments?

Also, how are awards such as energy regen, damage decrease, and damage increase assigned after a given amount of points? I've never seen any file regarding this. How does the medal system work?

And please no speculation. Thanks for any help I can get!

Re: Award Weapons

Posted: Tue Nov 17, 2009 6:12 am
by MercuryNoodles
The numbers, as I recall, are associated with the awards themselves. (I'm not sure if they're hardcoded or not, but I'm leaning toward the former.) The Unlock and Lock parameters are exactly that. Really, it's staring right at you. :P MedalsTypeToLock sets the weapon to be removed from your inventory when you achieve the award associated with that number, and MedalsTypeToUnlock does the opposite. The weapon odfs themselves shouldn't matter (provided they're functioning weapons), so long as you've entered the parameters properly, and given them to the unit.

I'm curious about the non-weapon awards myself. I've never seen anything related to them, either.

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:15 am
by YaNkFaN
the other weapons are point based so they possibly could be hardcoded and the game just keeps checking how many points you get and then gives you the medal

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:52 am
by biohazard
I have a quickie question. I commented out those two lines in my custom weapon's odf, but I still get the award from the weapon I copied the odf from. (This is a bad thing)

Hidden/Spoiler:
[WeaponClass]
ClassParent = "com_weap_inf_shotgun"
GeometryName = "imp_weap_inf_rifle.msh"

[Properties]
GeometryName = "imp_weap_inf_rifle"
HighResGeometry = "imp_1st_weap_inf_rifle"
OrdnanceName = "imp_weap_inf_blast_ord"

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

FireSound = "imp_weap_inf_shotgun_fire"
ChangeModeSound = "com_weap_inf_equip_med"
ReloadSound = "com_weap_inf_reload_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"



[Properties]
//ScoreForMedalsType = 5
//MedalsTypeToLock = 5

AnimationBank = "rifle"

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

RoundsPerClip = "96"
ReloadTime = "1.75"

SecondaryOrdnanceName = "com_weap_inf_shotgun_tracer"
SecondaryOrdnancePeriod = 1

ZoomMin = "1.4"
ZoomMax = "1.4"
ZoomRate = "0.0"

TriggerSingle = "1"
ShotDelay = "0.2"

PitchSpread = "2.0"
YawSpread = "5.0"

SpreadPerShot = "1.1"
SpreadRecoverRate = "4.8"
SpreadThreshold = "1.6"
SpreadLimit = "6.0"

StandStillSpread = "0.0"
StandMoveSpread = "0.0"
CrouchStillSpread = "0.0"
CrouchMoveSpread = "0.0"
ProneStillSpread = "0.0"
ProneMoveSpread = "0.0"

LockOnRange = "40.0"
LockTime = "0.0"
AutoAimSize = "1.0"

MinRange = "0"
OptimalRange = "24"
MaxRange = "48"
AIUseBubbleCircle = "1"
AIBubbleSizeMultiplier = "1.25"

SalvoCount = "1"
ShotsPerSalvo = "16"
SalvoDelay = "0.2"
InitialSalvoDelay = "0.0"

TargetEnemy = "1"
TargetNeutral = "0"
TargetFriendly = "0"

TargetPerson = "1"
TargetAnimal = "1"
TargetDroid = "1"
TargetVehicle = "0"
TargetBuilding = "0"

Re: Award Weapons

Posted: Tue Nov 17, 2009 11:21 am
by kinetosimpetus
set them to -1

Re: Award Weapons

Posted: Tue Nov 17, 2009 6:44 pm
by trainmaster611
@Bio: make sure you commented out the MedalsTypeToUnlock and the ScoreForMedalsType in the award weapons too. And make sure you commented out those lines in the common weapon odf and the common award weapon odf. The -1 actually messes something up.
MercuryNoodles wrote:The numbers, as I recall, are associated with the awards themselves. (I'm not sure if they're hardcoded or not, but I'm leaning toward the former.) The Unlock and Lock parameters are exactly that. Really, it's staring right at you. :P MedalsTypeToLock sets the weapon to be removed from your inventory when you achieve the award associated with that number, and MedalsTypeToUnlock does the opposite. The weapon odfs themselves shouldn't matter (provided they're functioning weapons), so long as you've entered the parameters properly, and given them to the unit.
YaNkFaN wrote:the other weapons are point based so they possibly could be hardcoded and the game just keeps checking how many points you get and then gives you the medal
Yeah, those were my suspicions. But where that theory breaks down is the fact that the MedalsTypeto(Un)Lock and ScoreForMedalsType always have the same values in the weapon odfs. For example, in the pistol, both values are 0, in the rifle, both values are 1, in the snipe rifle, both values are 4, and so on. It seems to me that would be an odd coincidence. And I know that the award pistol takes 6 kills to unlock, the award rifle 12 kills to unlock, and the snipe rifle 6 headshots to unlock. And those values obviously don't correspond.

I think what we understand is that the value does indeed describe the necessary accomplishment needed to unlock the award weapon and the values help to correlate the primary and award weapons.

So what is the difference between those parameters?

Re: Award Weapons

Posted: Tue Nov 17, 2009 6:56 pm
by kinetosimpetus
what does -1 mess up?

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:03 pm
by AQT
trainmaster611 wrote:So what is the difference between those parameters?
ScoreForMedalsType earns you a medal for an award which is recorded in your profile's career stats. MedalsTypeto(Un)Lock gives you the actual award to use/that becomes in effect.

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:04 pm
by kinetosimpetus
so could you use unlock without using scoring? or vice versa?

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:07 pm
by AQT
Probably not, though you can score but not unlock.

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:19 pm
by Fiodis
Is it hardcoded to determine whether you need a set amount of headshots or kills to unlock a weapon?

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:30 pm
by trainmaster611
Fiodis wrote:Is it hardcoded to determine whether you need a set amount of headshots or kills to unlock a weapon?
From what others have been saying (and in previous topics) the answer is yes. Each number has its own accomplishment like so:
0 = 6 kills with a pistol
1 = 12 kills with a rifle
2 = 4 critical hits with a rocket launcher
3 = Vehicle Hack
4 = 6 headshots with a snipe rifle
5 = 8 kills with a shotgun
6 = 8 points
7 = 12 points
8 = 18 points
And this all has to be done in one life of course. I think this chart is accurate.

What I'm thinking is that you would have to pick one of those accomplishments to be the accomplishment to unlock the award weapon. For example, pick 0 for a weapon and the award weapon will be unlocked after 6 kills. I've already tried this ingame though, and it didn't seem to work. I don't know if I'm doing something wrong or if my thinking is incorrect.

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:43 pm
by kinetosimpetus
Can someone explain exactly what using -1 messes up?

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:46 pm
by RED51
trainmaster611 wrote:
Fiodis wrote:Is it hardcoded to determine whether you need a set amount of headshots or kills to unlock a weapon?
From what others have been saying (and in previous topics) the answer is yes. Each number has its own accomplishment like so:
0 = 6 kills with a pistol
1 = 12 kills with a rifle
2 = 4 critical hits with a rocket launcher
3 = Vehicle Hack
4 = 6 headshots with a snipe rifle
5 = 8 kills with a shotgun
6 = 8 points
7 = 12 points
8 = 18 points
And this all has to be done in one life of course. I think this chart is accurate.

What I'm thinking is that you would have to pick one of those accomplishments to be the accomplishment to unlock the award weapon. For example, pick 0 for a weapon and the award weapon will be unlocked after 6 kills. I've already tried this ingame though, and it didn't seem to work. I don't know if I'm doing something wrong or if my thinking is incorrect.
That seems about right. I'll try it out with PF.

Re: Award Weapons

Posted: Tue Nov 17, 2009 7:49 pm
by trainmaster611
@Kinetos: Go search 'removing award weapons' and you'll find the answer. That's not really relevant to this topic.

Anyways, I think I am right. I accidentally mixed up some of the values and that's why it wasn't working. When I assigned 1 to the values in question, the award weapon was unlocked after 12 kills. But this still needs to be looked into a bit more.

Does anyone know how the Energy Regen, Damage Increase, and Damage Decrease are connected to their respective medals (ie, Gaurdian, etc.)?

[edit]

Ok, so when I tried using the 4 value, I gained the medal when I got 6 headshots, but it didn't unlock the award weapon. When I tried using 0, I again got the medal but no award weapon. So we're on the right track but I'm not sure whats wrong.

Re: Award Weapons

Posted: Tue Nov 17, 2009 8:20 pm
by kinetosimpetus
trainmaster611 wrote:The -1 actually messes something up.
like what?
trainmaster611 wrote:Go search 'removing award weapons' and you'll find the answer.
topic searched = yes
answer found = yes
answer = nothing

trainmaster611 wrote:Ok, so when I tried using the 4 value, I gained the medal when I got 6 headshots, but it didn't unlock the award weapon. When I tried using 0, I again got the medal but no award weapon. So we're on the right track but I'm not sure whats wrong.
Did you change the values in the award weapon also?

Re: Award Weapons

Posted: Tue Nov 17, 2009 9:05 pm
by RogueKnight
trainmaster611 wrote:The -1 actually messes something up.
It doesn't mess anything up, it just turns off the ability to gain the award weapon.

Re: Award Weapons

Posted: Tue Nov 17, 2009 9:19 pm
by trainmaster611
DarthRogueKnight wrote:
trainmaster611 wrote:The -1 actually messes something up.
It doesn't mess anything up, it just turns off the ability to gain the award weapon.
I don't get why this needs to be so difficult.

http://www.gametoast.com/forums/viewtop ... 27&t=15618

Remove and/or comment out the lines unless the parent ODF mentions them in which case you need to override them with -1. Either way, it doesn't matter.

Can we get back on topic now?

Re: Award Weapons

Posted: Tue Nov 17, 2009 9:30 pm
by Fiodis
trainmaster611 wrote:Ok, so when I tried using the 4 value, I gained the medal when I got 6 headshots, but it didn't unlock the award weapon. When I tried using 0, I again got the medal but no award weapon. So we're on the right track but I'm not sure whats wrong.
Interesting. When did you, if ever, gain the award weapon?

EDIT - Oh wait, did you set the value to 4 (or 0) in both the normal and the award weapon?

Re: Award Weapons

Posted: Tue Nov 17, 2009 10:19 pm
by trainmaster611
Fiodis wrote:
trainmaster611 wrote:Ok, so when I tried using the 4 value, I gained the medal when I got 6 headshots, but it didn't unlock the award weapon. When I tried using 0, I again got the medal but no award weapon. So we're on the right track but I'm not sure whats wrong.
Interesting. When did you, if ever, gain the award weapon?

EDIT - Oh wait, did you set the value to 4 (or 0) in both the normal and the award weapon?
The only time I got the award weapon is if I set the value to 1. The weapon belonged to a rifleman so I'm wondering if that's what made the difference. And yes, I made sure I set the values in both the primary and award weapon.