Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[Bug] UnitspecificSounds block doesn't have diagnostics

Open
#30 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
rust, vscode

Research direction

Start by locating the schema handling for UnitSpecificSounds and DialogEvents in the ZeroSyntax language server, then compare it with the listed module sources such as CommandXlat.cpp and SpecialAbilityUpdate.cpp. Use the minimal INI sample to check how the fields are parsed. Done means the listed sound fields provide diagnostics and autocompletions without requiring users to define unused fields.

Written by the indexing model from the issue text.

Description

bug

What happened?

Certain modules in an object can expose additional sound fields the object can attempt to call. Typically these fields are defined within the UnitSpecificSounds block, but it seems to be just in the Object scope.

Expected behavior

The fields inside the UnitSpecificSounds should be parsed in the schema and have diagnostics and autocompletions for the DialogEvents. Additionally I think some hints on the modules which provide additional sound fields would be a great way to show this to the user. It shouldn't be enforced as the user might not want to use the field. The alternative to this would be forcing the user to set the fields to NoSound, which I don't see being friendly.

List of UnitSpecificSounds found so far:

Module / Source Categoty Sound Key(s)
CommandXlat.cpp GameClient / Commands Translator VoiceSupply, VoiceUnload, VoiceRepair, VoicePickup, VoiceCombatDrop, VoiceGetHealed, VoiceEnterHostile, VoiceGarrison, VoiceEnter, VoiceCrush, VoiceSalvage, VoiceMoveUpgraded, VoiceBuildResponse, VoicePrimaryWeaponMode, VoiceSecondaryWeaponMode, VoiceTertiaryWeaponMode, VoiceBombard, VoiceClearBuilding, VoiceSubdue, VoiceDisarm, VoiceSnipePilot, VoiceMelee, VoiceFlameLocation, VoicePoisonLocation, VoiceFireRocketPods, VoiceHackInternet
PlaceEventTranslator.cpp GameClient / Placement VoiceNoBuild
BuildAssistant.cpp Common / Build system VoiceCreated
ProductionUpdate.cpp Update module VoiceCreate
StickyBombUpdate.cpp Update module StickyBombCreated, UnitBombPing
StealthUpdate.cpp Update module DisguiseStarted, DisguiseRevealedSuccess, DisguiseRevealedFailure
SpectreGunshipUpdate.cpp Update module Afterburner, HowitzerFire
SpecialAbilityUpdate.cpp Update module VoiceCaptureBuildingComplete, VoiceDisableVehicleComplete, VoiceStealCashComplete
DeliveryPayloadAIUpdate.cpp AIUpdate module StartDive
JetAIUpdate.cpp AIUpdate module VoiceLowFuel, Afterburner
HackInternetAIUpdate.cpp AIUpdate module UnitUnpack, UnitPack, UnitCashPing
DozerAIUpdate.cpp AIUpdate module UnderConstruction
DeplayStyleAIUpdate AIUpdate module Deploy, Undeploy
FiringTracker.cpp Object helper VoiceRapidFire
EjectPilotDie.cpp Die module VoiceEject, SoundEject
TurretAI.cpp AI Helper TurretMoveLoop

Requires more attention to find the specifics, as it seems some SpecialPowers introduces some of the fields and not nessearly the module itself, but the specialpower used in the module.

Minimal INI sample

  UnitSpecificSounds
    VoiceCreate = BlackLotusVoiceCreate
    VoiceGarrison = BlackLotusVoiceMove
    VoiceEnter = BlackLotusVoiceMove
    VoiceEnterHostile = BlackLotusVoiceMove
    VoiceStealCashComplete = BlackLotusVoiceCashComplete
    VoiceDisableVehicleComplete = BlackLotusVoiceDisableComplete
    VoiceCaptureBuildingComplete = BlackLotusVoiceCaptureComplete
    VoiceGetHealed = BlackLotusVoiceMove
  End
Behavior = SpecialAbility ModuleTag_08
    SpecialPowerTemplate = SpecialAbilityBlackLotusCaptureBuilding
    UpdateModuleStartsAttack = YES
    InitiateSound = BlackLotusVoiceHackBuilding
  End
  Behavior = SpecialAbilityUpdate ModuleTag_09
    SpecialPowerTemplate = SpecialAbilityBlackLotusCaptureBuilding
    StartAbilityRange = 150.0
    PreparationTime = 6000 ; the time to complete the hack once prepared (unpacked)
    SpecialObject = BinaryDataStream
    UnpackTime = 6730 ; animation time is 6730 (changing this will scale anim speed)
    PackTime = 2800 ; animation time is 5800 (changing this will scale anim speed)
    DoCaptureFX = YES
    PackSound = BlackLotusPack
    UnpackSound = BlackLotusUnpack
    TriggerSound = BlackLotusTrigger
    PrepSoundLoop = BlackLotusPrepLoop
    AwardXPForTriggering = 20
    ; SkillPointsForTriggering = ??? ; Dustin, fill me out if you want different balance values.
  End
  Behavior = SpecialAbility ModuleTag_10
    SpecialPowerTemplate = SpecialAbilityBlackLotusDisableVehicleHack
    UpdateModuleStartsAttack = YES
    InitiateSound = BlackLotusVoiceHackVehicle
  End
  Behavior = SpecialAbilityUpdate ModuleTag_11
    SpecialPowerTemplate = SpecialAbilityBlackLotusDisableVehicleHack
    StartAbilityRange = 150.0
    PreparationTime = 2000 ; the time to complete the hack once prepared (unpacked)
    EffectDuration = 15000 ; duration the vehicle is disabled
    DisableFXParticleSystem = DisabledEffectBinaryShower0
    SpecialObject = BinaryDataStream
    UnpackTime = 2000 ; animation time is 6730 (changing this will scale anim speed)
    PackTime = 1000 ; animation time is 5800 (changing this will scale anim speed)
    PackSound = BlackLotusPack
    UnpackSound = BlackLotusUnpack
    TriggerSound = BlackLotusTrigger
    PrepSoundLoop = BlackLotusPrepLoop
    AwardXPForTriggering = 0
    ; SkillPointsForTriggering = ??? ; Dustin, fill me out if you want different balance values.
  End
  Behavior = SpecialAbility ModuleTag_12
    SpecialPowerTemplate = SpecialAbilityBlackLotusStealCashHack
    UpdateModuleStartsAttack = YES
    InitiateSound = BlackLotusVoiceHackCash
  End
  Behavior = SpecialAbilityUpdate ModuleTag_13
    SpecialPowerTemplate = SpecialAbilityBlackLotusStealCashHack
    StartAbilityRange = 150.0
    PreparationTime = 6000 ; the time to complete the hack once prepared (unpacked)
    EffectValue = 1000 ; amount of cash stolen
    SpecialObject = BinaryDataStream
    UnpackTime = 6730 ; animation time is 6730 (changing this will scale anim speed)
    PackTime = 5800 ; animation time is 5800 (changing this will scale anim speed)
    PackSound = BlackLotusPack
    UnpackSound = BlackLotusUnpack
    TriggerSound = BlackLotusTrigger
    PrepSoundLoop = BlackLotusPrepLoop
    AwardXPForTriggering = 20
    ; SkillPointsForTriggering = ??? ; Dustin, fill me out if you want different balance values.
  End

Environment

  • OS: Windows 11
  • Editor: Vscode
  • ZeroSyntax version: 1.0.3
Dominant language
Rust
Stars
1
Forks
0
Avg merge
15h 8m
Merged PRs (30d)
11

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ViTeXFTW/ZeroSyntaxV2

All issues in ViTeXFTW/ZeroSyntaxV2

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.