Author Topic: "Limited Grenades" code. (NEW INFO SINCE 2.25!)  (Read 1956 times)

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
"Limited Grenades" code. (NEW INFO SINCE 2.25!)
« on: 04-12-2009, 17:12:00 »
The thing that limits grenades on some maps is a little wonky.  We all know that the German HEAT RifleNade (for example, on PdH) was omitted from the list of things that the code limits.  Well, while on a WaW map yesterday, I noticed that the British No.4 Mills Bomb Launcher was also seemingly omitted from the list of things the code limits.  It's odd, because since the Mills Bomb Launcher shares ammo with the thrown Mills Bomb (which is limited), if you throw a Mills Bomb before using the launcher, the Launcher has one less Nade to launch.  I didn't check to see what happens if you launch one then try to throw one, though.

Anyway, I know there aren't any maps that the British have the Mills Bomb Launcher that also has the "Limited Grenades" code in the mod right now, but as shown, it affects custom maps, and maybe future official maps as well.

Somewhat unrelated, but why do only the British in Normandy have Mills Bomb Launcher?  From what I've read, all CommonWealth forces had the base plates that screw onto the Mills Bombs, which is all you need to use the Mills Bomb with the Standard No.4 (and SMLE) Rifle Nade Launcher Cup.  The British and Australians in Africa (even when they have the No.1 MkIII* SMLE), as well as the Canadians in Normandy should all have the Mills Bomb Launcher too...  Even if the Canadians and Australians didn't have them, the British in Africa definitely should...
« Last Edit: 19-01-2010, 03:01:17 by Ionizer »
 

Offline Eat Uranium

  • Tea Drinker
  • Global Moderator
  • *****
  • Posts: 4.527
  • Today's news will contain [REDACTED]
    • View Profile
    • FH2 Music
Re: "Limited Grenades" code.
« Reply #1 on: 04-12-2009, 17:12:45 »
Somewhat unrelated, but why do only the British in Normandy have Mills Bomb Launcher?  From what I've read, all CommonWealth forces had the base plates that screw onto the Mills Bombs, which is all you need to use the Mills Bomb with the Standard No.4 (and SMLE) Rifle Nade Launcher Cup.  The British and Australians in Africa (even when they have the No.1 MkIII* SMLE), as well as the Canadians in Normandy should all have the Mills Bomb Launcher too...  Even if the Canadians and Australians didn't have them, the British in Africa definitely should...
Hear hear!

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
Re: "Limited Grenades" code.
« Reply #2 on: 09-12-2009, 04:12:26 »
Any actual comments from Devs or anyone on this(these) issue(s)?  Like if this is already known or if it's being looked into or if it's fine as is?
 

Offline Kev4000

  • Developer
  • ******
  • Posts: 1.039
  • FH2 "special" coder
    • View Profile
Re: "Limited Grenades" code.
« Reply #3 on: 13-12-2009, 05:12:21 »
Fixed the fewer grenades - should now work with custom maps using the code.

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
Re: "Limited Grenades" code.
« Reply #4 on: 09-01-2010, 02:01:35 »
This wasn't ever fixed.  On Actoville, the Mills Bomb Launcher still is not limited by the limited grenade code.  The throw-able Mills Bomb and the Mills Bomb Launcher are still ammo linked, so if you throw your one Mills Bomb, you can still launch two more.

I don't understand.  It works fine for the American throw-able Mk II Frag Grenade and the Garand Mk II Frag Grenade Launcher, why wouldn't it work with the Mills Bomb?
 

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
Re: "Limited Grenades" code.
« Reply #5 on: 09-01-2010, 21:01:59 »
Anyone?  Other bug reports got confirmation...  Should I make a new thread?
 

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
Re: "Limited Grenades" code.
« Reply #6 on: 19-01-2010, 03:01:58 »
Last time I'm bumping this.  I forgot you can change the thread name.  So I did that.  If no one posts, I'll PM Kev, since he said he fixed it.

Also, I look like a jackass triple bumping a thread.  Oh well.
 

Offline [130.Pz]S.Lainer

  • FH-Betatester
  • ***
  • Posts: 1.934
    • View Profile
    • 130th
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #7 on: 19-01-2010, 06:01:17 »
  There you go Ionizer.  I will share in the pain.
http://www.bfewaw.com/campaigns/waw24/promo/campaign/waw24banner1.png
The purpose of this deployment was to "annoy and defy the United States ... on her with Bofors 40 mm guns from a range of 650

Offline Gunnie

  • Developer
  • ******
  • Posts: 124
    • View Profile
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #8 on: 19-01-2010, 16:01:38 »
What exactly is the issue? Kit limiting or ? I don't follow the grenade limiting problem as there is no "specific grenade limiting" in the python code of the mod that I am aware of. You can limit kits, but I am not aware of specifically limiting grenades.

Unless you are talking about the hand thrown vs launched grenades and limiting them by mag-linking? If this is the case, you need to keep in mind that there are more than one type of hand thrown grenade.  Depending on how the kits are setup, perhaps the grenade in the kit is not the same grenade that is mag-linked to the launcher? There are variations of the handgrenades to limit "quantity".  If the grenade in the kit does not match the launcher in the kit.. Wonky things will be the norm.

There would be no grenade kit limiting in effect as the launcher and grenade are two seperate items. Both will still function and both will still be available.  As an example.. The No.4 Mills grenade launcher is mag-linked to the "millsbomb-3" hand grenade. This means that the kit of the soldier would have to be using this hand grenade for the mag link to work. If the kit is using just the "millsbomb" version of the hand grenade. Then it is not going to work. The mag-link will not subtract from the total number of hand grenades. Since the hand grenade it is supposed to subtract is not being carried by the soldier.

Offline Ionizer

  • Full Member
  • ***
  • Posts: 1.524
  • Carrier of Squirrel Flu
    • View Profile
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #9 on: 19-01-2010, 23:01:13 »
OKay, the old problem is that it didn't work on a WaW map.  The new problem is that it doesn't work on Anctoville, an official map.

The British Rifleman on Anctoville has a throw-able Mills Bomb.  He also has the Cup Launcher on his No.4 that can launch Mills Bombs, using the same ammo count as the thrown ones.  Anctoville is a small map, so the limited grenades code (where you only get one of each type of grenade you are equipped with) is active.  So you get 1 throw-able Mills Bomb, one No.4 Heat Grenade and... 3 Launch-able Mills Bombs.  If you throw your one Mills Bomb, you can still Launch 2 more out of the Cup thing, so the the weapons are obviously ammo-linked.  This obviously isn't correct, because, for example, on Pointe Du Hoc (another map with limited grenades code), the American Rifleman has one throw-able Mk.II Frag Grenade, one Garand Heat Rifle Grenade and one Launch-able Mk.II Frag Grenade; in that kit, the two Frag Grenades are ammo-linked, meaning if you throw one, you can't launch one unless you get more ammo. 

I believe the problem is that the No.4 Mills Bomb Launcher was omitted from the Limited Grenades code, similar to how the German HEAT Rifle Grenade was omitted from it for 2.2.  It's just that this incarnation of the same oversight has a funky side effect because the No.4 Mills Bomb Launcher (not limited) is ammo-linked with the thrown Mills Bomb (which is limited).  The net effect is that the British on Anctoville have more grenades than the Germans, with the added oddity of only being able to launch the extras instead of throwing them.
 

Offline Gunnie

  • Developer
  • ******
  • Posts: 124
    • View Profile
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #10 on: 20-01-2010, 04:01:06 »
Okay.. Now I understand.. You are talking about number of grenades in the kits and limiting how many the soldier has. That's not done in python..  ;D  That is done via .inc file within the mods objects/common folder.

Well.. Looking at the code of the map.. It appears that the grenade limiting is being done map-side and not mod-side.  On PDH, the greanade limiting is done via the mod. ie.. In the tmp.con  and it is pointing to the .inc file for limiting the grenades in the kits that is in the common folder. (How this should be done.)

Where in Anctoville, it is being done within the map itself, by pointing to an .inc file that is packed into the map. (Works on some things, but not the best way to run something if you can avoid it.) I will talk with Natty and see about pointing this to the mod and not running it map side and see if that fixes it.

Offline ZeeJarMans

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #11 on: 20-01-2010, 04:01:05 »
I'd assumed the British would have been using the 2inch mortar..instead of a rifle grenade... ::)
Yes Zee Jarmans are comming...hahaha

Offline Kev4000

  • Developer
  • ******
  • Posts: 1.039
  • FH2 "special" coder
    • View Profile
Re: "Limited Grenades" code. (NEW INFO SINCE 2.25!)
« Reply #12 on: 20-01-2010, 22:01:37 »
Yep for some reason Ancto is running its own custom fewer grenades code. I did indeed fix it on my end though.

Finally something I didn't break  ;D