Page MenuHomeFeedback Tracker

Weapon manipulation commands
Closed, ResolvedPublic

Description

Weapon manipulation functions with new inventory system are urgently needed, as it breaks some important functionality; see "Use cases" in additional info.

New get functions:

  • currentPrimaryMagazine <unit>: return the class name of the currently loaded

magazine on primary weapon

  • currentPrimaryMagazine [<unit>,<muzzle>]: return the class name of the currently loaded magazine on primary weapon by selecting the muzzle (e.g. grenade launcher)
  • currentSecondaryMagazine <unit>: return the class name of the currently loaded magazine on secondary weapon
  • currentHandgunMagazine <unit>: return the class name of the currently loaded magazine in the handgun

New set functions:

  • <unit> loadPrimaryMagazine <magazine>: create a magazine and load it into referenced weapon of a unit OR enable 'addMagazine' to work with <weapon>
  • <unit> loadPrimaryMagazine [<magazine>,<muzzle>]: overloaded function - allow to load certain magazines into different muzzles of a weapon, e.g. a grenade launcher; <muzzle> is a number; invalid combinations must be ignored
  • <unit> loadSecondaryMagazine <magazine>: create a magazine and load it into referenced weapon of a unit OR enable 'addMagazine' to work with <weapon>
  • <unit> loadHandgunMagazine <magazine>: create a magazine and load it into referenced weapon of a unit OR enable 'addMagazine' to work with <weapon>
  • unloadPrimaryMagazine <unit>: remove a loaded magazine from the referenced weapon
  • unloadSecondaryMagazine <unit>: remove a loaded magazine from the referenced weapon
  • unloadHandgunMagazine <unit>: remove a loaded magazine from the referenced weapon

Details

Legacy ID
2829212625
Severity
Feature
Resolution
Fixed
Reproducibility
N/A
Operating System
Windows 7
Category
Scripting
Additional Information

Use case 1:
I want to save the entire inventory of a unit into variables and load/restore it again onto a unit; there is currently no (easy) way to get currently loaded magazines.

Use case 2:
I want to load a rocket directly into a launcher weapon; if the inventory is at capacity, there is currently no way to provide a magazine directly to a weapon.

Event Timeline

Fireball edited Steps To Reproduce. (Show Details)Mar 31 2013, 1:48 AM
Fireball edited Additional Information. (Show Details)
Fireball set Category to Scripting.
Fireball set Reproducibility to N/A.
Fireball set Severity to Feature.
Fireball set Resolution to Open.
Fireball set Legacy ID to 2829212625.May 7 2016, 1:19 PM
dedmen added a subscriber: dedmen.Sep 13 2017, 12:24 PM

handgunMagazine, addWeaponItem and more..
All solved.

It's solved. Ticket can be closed.

Dwarden closed this task as Resolved.Jan 19 2020, 10:08 AM
Dwarden updated the task description. (Show Details)
Dwarden changed Resolution from Open to Fixed.
Dwarden edited Steps To Reproduce. (Show Details)
Dwarden edited Additional Information. (Show Details)
Dwarden set Operating System to Windows 7.