WeaponsDialog.h file
Namespaces
- namespace Jazz2
- Root namespace of Jazz² Resurrection.
- namespace Jazz2::Editor
Functions
- void ShowWeaponsDialog(IEditorContext& session)
- Shows the weapons of the level.
- auto ReadLevelWeapons(const LevelDocument& document, LevelWeapons& weapons) -> Formats::WeaponsChunk::ReadResult
- Reads the weapons of a level, returns why if they can't be changed, see Formats::
WeaponsChunk:: Read(). -
auto ChangeLevelWeapons(IEditorContext& session,
StringView name,
Death::
Containers:: Function<void(LevelWeapons&)>&& change, bool final = true) -> bool - Changes the weapons of the level as an undoable step, changes while a value is dragged are merged until
final. - auto GetLevelWeaponName(const WeaponsDescription& weapons, WeaponType weaponType) -> String
- Returns the name of a weapon, as the level names it or as the game does.
- auto GetStockWeaponName(WeaponType weaponType) -> StringView
- Returns the name of a weapon of the game.
- auto GetCachedLevelWeapons(IEditorContext& session) -> const LevelWeapons&
- Returns the weapons of the level being edited, read again only when they changed.
- auto GetEventOptionLabel(IEditorContext& session, const EventParamField& field, const ParamOption& option) -> String
- Returns the label of an option of a parameter of an event.
Function documentation
void ShowWeaponsDialog(IEditorContext& session)
Shows the weapons of the level.
Each of the weapons can keep the weapon of the game with other options, be a custom weapon the level describes — with a preview of its shots and a play-test to try it — or a weapon the script of the level sets up.
const LevelWeapons& GetCachedLevelWeapons(IEditorContext& session)
Returns the weapons of the level being edited, read again only when they changed.
For what asks for them every frame. They're as the game has them if they can't be read.
String GetEventOptionLabel(IEditorContext& session, const EventParamField& field, const ParamOption& option)
Returns the label of an option of a parameter of an event.
An option of a weapon (see EventParamField::