Build 9881
GIT-
Fix an error with the bonus tile, and extend EVENT_GETBONUSTILE
Show details
Within EVENT_GETBONUSTILE, you can now set ud.return[0] to ud.return[4] to change each frame of the bonus screen animation separately.
SVN handles and Git names are merged into one person.
Fix an error with the bonus tile, and extend EVENT_GETBONUSTILE
Within EVENT_GETBONUSTILE, you can now set ud.return[0] to ud.return[4] to change each frame of the bonus screen animation separately.
Add event EVENT_GETBONUSTILE to change bonus screen pic
The RETURN value will be set to the current base bonusscreen tile, and changing it will change the tiles displayed in the bonusscreen.
Only attempt to switch subweapon if we actually have the weapon
This fixes a bug in World Tour where trying to switch to the flamethrower while the current weapon is the freezer, and you have flamethrower ammo but not the actual weapon itself, then this instead locks the weapon key, preventing you from switching back to the freezer from other weapons. This bug also affected the Shrinker, but only if CON code changes the 'gotweapon 11' value to 0 after the player obtains the weapon.
Reset all actor vars in prelevel() regardless of the sprite's statnum
Previously, only sprites with statnum 0 would have their per-actor variables reset to the default on map load. This meant that sprites with statnums that were pre-defined in the map would inherit the actor var values of the sprites with corresponding spriteNums from the previous map. Additionally, the per-actor var reset is now performed before EVENT_PRELEVEL, meaning that any changes to actorvar that occur in this event will now persist. Previously, altering actor vars for sprites with statnum 0 in this event would not have any effect, as they would be reset to their defaults afterwards.
Add sanity checking to CON decimals, hex constants and labels
* Scripts no longer compile if a hex constant is malformed (e.g. 0x, 0xz) * Compiler will now warn if a decimal or hex constant isn't terminated in a sane manner. (example: digit is followed by letters: "100ab") * Compiler will now warn if a label starts with digits. This is done to prevent ambiguity between integer constants and actual labels.
WIP controller force feedback (rumble) support
Currently hard-coded with no real customization; algorithm and range of values will certainly change but the current implementation attempts to automatically discern appropriate force feedback values based on the potential damage inflicted by projectiles the player fires, events occurring in the map such as explosions and earthquakes, and on the damage the player receives. A future commit will likely contain a way to send the force feedback impulses from CON.
make actors set to move vertically in CON act as if SFLAG_SMOOTHMOVE was explicitly enabled
This smooths out stuff like octabrains and flying liztroops without making them look stupid when they move on the ground.
Add the CON commands `getngcflags` and `setngcflags`
Usage: ``` getngcflags <var> <idx1> [<idx2>...] setngcflags <const/var> <idx1> [<idx2>...] ``` Gets/sets the flags for the newgamechoices entries at the specified indices. The index list is variable-sized, up to a maximum of 3. This can be used to enable/disable the MEF_Hidden and MEF_Locked state. Supersedes the userdef struct members: `m_newgamecustomopen` and `m_newgamecustomsubopen`.
add predefined TILE_ANIM and TILE_VIEWSCR tokens for CON
remove extra S_SoundIsValid() check from A_PlaySound()
This is checked in both S_PlaySound() and S_PlaySound3D() anyway, and we need to get to that stage of execution in order for EVENT_SOUND to fire.
zero player .horizRecenter and .horizSkew when zeroing return_to_center from CON
additional gamevar verification when loading savegames
add predefined MAXLEVELS and MAXVOLUMES for CON
in EVENT_LOADGAME, give RETURN a default value equaling the userbytever field from the savegame header and relax sv_loadheader() check
add xfliphighlightedsectors/yfliphighlightedsectors/xmirrorhighlightedsectors/ymirrorhighlightedsectors to m32script, remove read-only flag from startpos vars so the map start position can be changed from scripts
Add events EVENT_PREUPDATEANGLES and EVENT_POSTUPDATEANGLES
These events trigger once every frame and provide access to the input struct value updates of each frame. This makes it possible to alter input.q16avel and input.q16horz again, even with smooth mouse aiming. Addresses terminx/eduke32#132
Improve the CON_ADDLOGVAR command
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.
Expose 8 additional clipboard variables as READONLY to M32 CON
These variables include: * `tempxpanning` * `tempypanning` * `tempxvel` * `tempyvel` * `tempzvel` * `tempstatnum` * `tempblend` * `tempsectnum`
Update g_animPtr before and after cutscene loops
This will allow all CUTSCENE events to use the ifcutscene command. Before, only EVENT_CUTSCENE for ANM files could use it.
break from CON while loops on VM_RETURN
This should fix terminx/eduke32#16
CON control over player height and other properties
You're gonna have to talk to me or read the source for full details on usage, sorry. These are also all still liable to change in future builds, either in name or in functionality.
per-player gravity control through .gravity member of player struct
The default value is 256 (GRAVITATIONALCONSTANT value from USER.CON + 80).
fix incorrect sound_t struct member type
This didn't really affect anything because this functionality isn't exposed to CON yet.
remove STATIC prefix from the CON dynamic label preprocessor definitions because it's ugly
This also adds bounds checking to the DYNAMICSOUNDMAP and DYNAMICTILEMAP macros, and reduces the size of the corresponding arrays to something more reasonable.
expose gotsector[] to CON for checking to see if a particular sector was drawn during the last frame
clamp m32script line drawing color range to 255 instead of 15
handle negative color indexes for m32script printext16 the same as the line drawing commands
Fix buffer overflows with parsing out of range strings in CON files