Author Topic: throwing experience for weapons which rely on throwing skill  (Read 7557 times)

Offline yrizoud

  • Commander
  • *****
  • Posts: 1024
    • View Profile
throwing experience for weapons which rely on throwing skill
« on: January 11, 2016, 03:35:01 pm »
Piratez includes several different weapons which rely on throwing skill when you "shoot" them : black powder bombs and molotovs, bows, knives. I really like how it lets you use recruits who have a bad shooting accuracy. Even weaker ones can be bowwomen with unlimited ammo.

However, there is the issue that these weapons don't train the right stat... The standard experience system gives "shooting experience" when you hit a hostile target with any ranged weapon (either directly or with splash damage), and this increases firing accuracy, not throwing.
So my suggestion would be for Extended to modify the experience system accordingly.
1) Ranged weapons which rely more on "throwing" than "shooting" should give throwing experience when hitting a hostile, instead of shooting experience.
2) In this case it should still trigger secondary experience gains (TU, energy,..)
Such rules can be hard-coded, because it only triggers in games/mods that include such weapons.

Now, personnally I wouldn't stop there, but I know this gets far from vanilla...
3) Grenade/proxies explosions which hit a hostile would give throwing experience instead of shooting experience. And still provide secondary experience, like in 2)
4) Throwing random stuff would stop giving throwing experience once the character has reached the average stat of a hired soldier.
5) For equity, I would give "shooting experience" to soldiers who shoot at a hostile target (even if they miss) if their shooting accuracy is under-average. This should not trigger secondary experience gain, because it's too easy to abuse.

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 8842
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: throwing experience for weapons which rely on throwing skill
« Reply #1 on: January 12, 2016, 10:18:33 am »
I agree, but:

4) Throwing random stuff would stop giving throwing experience once the character has reached the average stat of a hired soldier.

How about: when any damage is dealt? Or at least when an enemy is hit?

5) For equity, I would give "shooting experience" to soldiers who shoot at a hostile target (even if they miss) if their shooting accuracy is under-average. This should not trigger secondary experience gain, because it's too easy to abuse.

It would still be abused though. "Let everyone shoot everywhere for points." Nah.

Offline yrizoud

  • Commander
  • *****
  • Posts: 1024
    • View Profile
Re: throwing experience for weapons which rely on throwing skill
« Reply #2 on: January 12, 2016, 03:53:16 pm »
How about: when any damage is dealt? Or at least when an enemy is hit?
Rule 3 handles it (in vanilla it gives shooting accuracy and secondary gains, my proposal is to change the reward to throwing accuracy + secondary gains)
This rule 4 is about the experience you normally get from just throwing flares and such, I propose to stop giving it to soldiers who have reached the average stat. At this point, only two things will keep improving the stat : Hitting hostiles with timed explosives and proxies (rule 3) or direct hits with throwing-based weapons (rule 1)
It would still be abused though. "Let everyone shoot everywhere for points." Nah.
This is only a boost for sub-average soldiers, the ones that you would have sacked and replaced immediately if you had the cash. If such underdog sees enough action to shoot 40+ times at aliens, surviving 5+ missions, IMO they deserve to reach the status of "barely useful".

Online Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5477
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: throwing experience for weapons which rely on throwing skill
« Reply #3 on: January 12, 2016, 03:58:28 pm »
Piratez includes several different weapons which rely on throwing skill when you "shoot" them : black powder bombs and molotovs, bows, knives. I really like how it lets you use recruits who have a bad shooting accuracy. Even weaker ones can be bowwomen with unlimited ammo.

However, there is the issue that these weapons don't train the right stat... The standard experience system gives "shooting experience" when you hit a hostile target with any ranged weapon (either directly or with splash damage), and this increases firing accuracy, not throwing.
So my suggestion would be for Extended to modify the experience system accordingly.
1) Ranged weapons which rely more on "throwing" than "shooting" should give throwing experience when hitting a hostile, instead of shooting experience.
2) In this case it should still trigger secondary experience gains (TU, energy,..)
Such rules can be hard-coded, because it only triggers in games/mods that include such weapons.

Now, personnally I wouldn't stop there, but I know this gets far from vanilla...
3) Grenade/proxies explosions which hit a hostile would give throwing experience instead of shooting experience. And still provide secondary experience, like in 2)
4) Throwing random stuff would stop giving throwing experience once the character has reached the average stat of a hired soldier.
5) For equity, I would give "shooting experience" to soldiers who shoot at a hostile target (even if they miss) if their shooting accuracy is under-average. This should not trigger secondary experience gain, because it's too easy to abuse.

1/ agreed, but I would modify the condition a little bit ... "rely more on throwing" is hard to define... I would distinguish between arcing shot (trains throwing) and normal shot (trains firing)
2/ agreed
3/ this is hard-ish to do currently, oxc doesn't know about the weapon at this moment anymore, just knows the damage type (i.e. don't know if it was rocket launcher or grenade)
4/ I would limit this to throwing of primed grenades or proxies; or disposable items with clipsize = 1 (i.e. molotovs, powder bombs, acid flasks, ...)
5/ no

I am currently working on this... we'll see what I can do until evening.

Online Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5477
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: throwing experience for weapons which rely on throwing skill
« Reply #4 on: January 12, 2016, 05:16:57 pm »
OK, here's my proposal, already implemented.

Throwing training 1:
 - anytime a primed grenade is thrown anywhere
 - e.g. primed frag grenade, primed smoke grenade, ...

Throwing training 2:
 - anytime a primed proxy is thrown anywhere
 - e.g. primed landmine, ...

Throwing training 3:
 - anytime a disposable (weapon's clipSize=1) weapon with arcing trajectory is "fired" (i.e. not thrown!)
 - e.g. molotovs, black powder bombs, acid flasks

Throwing training 4:
 - anytime a non-disposable (i.e. stays in hand after fired) weapon with arcing trajectory is fired and enemy unit is hit (mind-controlled also count)
 - e.g. combat bow

Firing accuracy training 5:
 - anytime a non-disposable (i.e. stays in hand after fired) weapon with non-arcing trajectory is fired and enemy unit is hit (mind-controlled also count)
 - e.g. fuso knives, x-bow, sniper rifle, rocket launcher

There are no other ways to train throwing or firing accuracy.

Comments are welcome... but I cannot guarantee your wishes will be fulfilled.

PS: there are still ways to spam... but at least it either consumes the items (unlike flares previously) or burdens the soldier and endangers others (throwing heavy proxies)
PS2: bow finally trains throwing, yay!
PS3: fuso knives train firing though (based on rule 5), it's not so bad, and could be "fixed" by giving them arcing trajectory
« Last Edit: January 12, 2016, 05:22:39 pm by Meridian »

Offline Dioxine

  • Moderator
  • Commander
  • ***
  • Posts: 5220
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: throwing experience for weapons which rely on throwing skill
« Reply #5 on: January 12, 2016, 05:50:08 pm »
Meridian's solution seems the most sensible, although I'd add the condition of hitting an enemy to 1-3 as well (which I think would mean 2 would be gone), especially with decent Throwing training using bows available. Easier Throwing training isn't really needed, as Piratez starting/early game teams are supposed to be composed of specialists with weaknessess, not all-round-good soldiers. Yrizoud arguments about soldiers staying "useless" are unfounded, since the Dojo (training facility) has been moved down the science ladder and it can make every soldier from zero to hero within 2-3 months (it trains everything but psi, reactions and bravery).
« Last Edit: January 12, 2016, 05:52:24 pm by Dioxine »

Offline yrizoud

  • Commander
  • *****
  • Posts: 1024
    • View Profile
Re: throwing experience for weapons which rely on throwing skill
« Reply #6 on: January 12, 2016, 06:23:08 pm »
The fuso knives are indeed the reason why "weapon is arcing" didn't seem like the perfect criteria.
Meridian, did you modify the code that grants secondary stats? It should now count, otherwise the amazons will never improve rank/TU/stamina/health/strengh
It should look like the following, in BattleUnit.cpp
Code: [Select]
if (_expBravery || _expReactions || _expFiring || _expPsiSkill || _expPsiStrength || _expMelee)
Dioxine, sorry I didn't even know about Dojo :-[ And my resentment about "bad shooting accuracy = useless" is a leftover from vanilla UFO. Piratez provides ways for several other stats to come to the rescue.

Online Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5477
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: throwing experience for weapons which rely on throwing skill
« Reply #7 on: January 12, 2016, 06:28:49 pm »
Meridian, did you modify the code that grants secondary stats? It should now count, otherwise the amazons will never improve rank/TU/stamina/health/strengh
It should look like the following, in BattleUnit.cpp
Code: [Select]
if (_expBravery || _expReactions || _expFiring || _expPsiSkill || _expPsiStrength || _expMelee)

No, I forgot to add the throwing, dang it!
Thanks for the reminder; I'll fix it tomorrow.

Btw. the change is here if you want to see it: https://github.com/MeridianOXC/OpenXcom/commit/1e39183b919bcf1963eb8e2b6c8c18a834d8be6e

Offline Dioxine

  • Moderator
  • Commander
  • ***
  • Posts: 5220
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: throwing experience for weapons which rely on throwing skill
« Reply #8 on: January 12, 2016, 07:46:10 pm »
Arcing weapon is a good criterium, even if knives won't train the right skill - there are plenty of ways to train it anyway, and knives are powerful as hell. Naturally the best would be an item-based override, but... it'd involve tons and tons of work. At least that way you will be rotating soldiers (mortar -> knives, knives -> guns etc.)

Offline eisenefaust

  • Sergeant
  • **
  • Posts: 15
    • View Profile
Re: throwing experience for weapons which rely on throwing skill
« Reply #9 on: January 13, 2016, 04:10:23 am »
Rather than kluging together all these special cases, how hard would it be to add flags for which stat to handle experience point gain on events? It seems like it would be easy to add another variable to when filling out the weapon information from the file and check which stats are used in calculating accuracy and/or damage. That would also be cleaner implementation for a generic OXCE implementation imo.

Offline yrizoud

  • Commander
  • *****
  • Posts: 1024
    • View Profile
Re: throwing experience for weapons which rely on throwing skill
« Reply #10 on: January 13, 2016, 11:22:27 am »
Yes the code would be straightfoward, but there is like a hundred items in Piratez, I understand Dioxine's reluctance : It's one more piece of information to maintain forever.

Offline Dioxine

  • Moderator
  • Commander
  • ***
  • Posts: 5220
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: throwing experience for weapons which rely on throwing skill
« Reply #11 on: January 13, 2016, 11:52:41 am »
Yes the code would be straightfoward, but there is like a hundred items in Piratez, I understand Dioxine's reluctance : It's one more piece of information to maintain forever.

Just a hundred? Don't be ridiculous, it's over 500 :) But yeah that's the reason for my reluctance.

Offline Boltgun

  • Colonel
  • ****
  • Posts: 254
  • [UTTERANCES]
    • View Profile
    • Piratez let's play
Re: throwing experience for weapons which rely on throwing skill
« Reply #12 on: January 13, 2016, 11:59:55 am »
Giving throwing for arching trajectory is a simple solution that take out a lot of flare throws. Grenade launchers will also train throwing and that makes sense.

I am also thinking about melee 'guns' like chainsaws or hammers, should they give melee experience? Perhaps making all guns with a range of 1 give such experience would easily fix that.

Offline Dioxine

  • Moderator
  • Commander
  • ***
  • Posts: 5220
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: throwing experience for weapons which rely on throwing skill
« Reply #13 on: January 13, 2016, 12:50:22 pm »
I am also thinking about melee 'guns' like chainsaws or hammers, should they give melee experience? Perhaps making all guns with a range of 1 give such experience would easily fix that.

Seconded. And the knive problem? And! non-arcing guns with max range 2-10 should give Throwing experience. Any thrown weapons with better range are Arcing afaik, and there are no real guns with such limited range, with just a very few oddities (like the Whip... which should train throwing anyway!)

Online Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5477
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: throwing experience for weapons which rely on throwing skill
« Reply #14 on: January 13, 2016, 02:07:58 pm »
Fair enough.
I have split Rule 5 into 4 sub-rules

Rule 5a:
 - same as rule 5 with maxRange > 10, trains firing accuracy
 - e.g. x-bow

Rule 5b:
 - same as rule 5 with 1 < maxRange <= 10, trains throwing accuracy
 - e.g. fuso knives

Rule 5c:
 - same as rule 5 with maxRange = 1, trains melee accuracy
 - e.g. hammer

Rule 5d:
 - same as rule 5 with maxRange < 1, trains nothing
 - e.g. ???