Skip to content

Duke3D: Improve the CON_ADDLOGVAR command

Dino Bollinger requested to merge dibollinger/eduke32:addlogvar into master

The change in gamedef.cpp is intentional, and allows the use of integer constants as array or struct index, as well as the secondary index that some struct members have. I'm not sure why only labels were allowed previously, since the parser and the VM both seem to correctly parse, store, and access the constants.

Changes:

  • Passing struct members and player vars as argument now works.
  • If struct members are accessed without specifying the index, the command will display which index was used by the CON VM.
  • Enable use of constant values for array indexing in addlogvar
  • Enable logging of integer constants with addlogvar
  • General refactoring and code improvement.
Edited by Dino Bollinger

Merge request reports