Merge branch 'LifeMeterMessage' of https://github.com/kyzentun/stepmania

This commit is contained in:
Kyzentun
2014-08-25 02:33:53 -06:00
25 changed files with 525 additions and 408 deletions
+9
View File
@@ -8,6 +8,15 @@ ________________________________________________________________________________
StepMania current development
--------------------------------------------------------------------------------
2014/08/06
----------
* [ScreenGameplay] LifeMeterChangedP1 message is no longer broadcast for for
P2's lifemeter. Use LifeMeterChangedP2. "Life" and "StepsSecond" are passed
in the params table for the message.
* [LifeMeterBattery] CourseSongRewardLives metric added.
* [LifeMeter] LifeType, DrainType, and BatteryLives moved to PlayerOptions so
the players can have different settings.
2013/10/09
----------
* [CombinedLifeMeterTug] Added names and commands to Separator and Frame items.
+89 -89
View File
@@ -1001,98 +1001,101 @@
<Function name='GetStepsQueueWrapped'/>
</Class>
<Class name='PlayerOptions'>
<Function name='IsEasierForSongAndSteps'/>
<Function name='IsEasierForCourseAndTrail'/>
<Function name='TimeSpacing'/>
<Function name='MaxScrollBPM'/>
<Function name='ScrollSpeed'/>
<Function name='ScrollBPM'/>
<Function name='Boost'/>
<Function name='Brake'/>
<Function name='Wave'/>
<Function name='Expand'/>
<Function name='Boomerang'/>
<Function name='Drunk'/>
<Function name='Dizzy'/>
<Function name='Confusion'/>
<Function name='Mini'/>
<Function name='Tiny'/>
<Function name='Flip'/>
<Function name='Invert'/>
<Function name='Tornado'/>
<Function name='Tipsy'/>
<Function name='Bumpy'/>
<Function name='Beat'/>
<Function name='Xmode'/>
<Function name='Twirl'/>
<Function name='Roll'/>
<Function name='Hidden'/>
<Function name='HiddenOffset'/>
<Function name='Sudden'/>
<Function name='SuddenOffset'/>
<Function name='Stealth'/>
<Function name='Blink'/>
<Function name='RandomVanish'/>
<Function name='Reverse'/>
<Function name='Split'/>
<Function name='Alternate'/>
<Function name='Cross'/>
<Function name='Centered'/>
<Function name='Dark'/>
<Function name='Blind'/>
<Function name='Cover'/>
<Function name='RandAttack'/>
<Function name='NoAttack'/>
<Function name='PlayerAutoPlay'/>
<Function name='Tilt'/>
<Function name='Skew'/>
<Function name='Passmark'/>
<Function name='RandomSpeed'/>
<Function name='TurnNone'/>
<Function name='Mirror'/>
<Function name='Backwards'/>
<Function name='Left'/>
<Function name='Right'/>
<Function name='Shuffle'/>
<Function name='SoftShuffle'/>
<Function name='SuperShuffle'/>
<Function name='NoHolds'/>
<Function name='NoRolls'/>
<Function name='NoMines'/>
<Function name='Little'/>
<Function name='Wide'/>
<Function name='Big'/>
<Function name='Quick'/>
<Function name='BMRize'/>
<Function name='Skippy'/>
<Function name='Mines'/>
<Function name='AttackMines'/>
<Function name='Echo'/>
<Function name='Stomp'/>
<Function name='Planted'/>
<Function name='Floored'/>
<Function name='Twister'/>
<Function name='HoldRolls'/>
<Function name='NoJumps'/>
<Function name='NoHands'/>
<Function name='NoLifts'/>
<Function name='NoFakes'/>
<Function name='NoQuads'/>
<Function name='NoStretch'/>
<Function name='MuteOnError'/>
<Function name='NoteSkin'/>
<Function name='FailSetting'/>
<Function name='Backwards'/>
<Function name='BatteryLives'/>
<Function name='Beat'/>
<Function name='Big'/>
<Function name='Blind'/>
<Function name='Blink'/>
<Function name='Boomerang'/>
<Function name='Boost'/>
<Function name='BMRize'/>
<Function name='Brake'/>
<Function name='Bumpy'/>
<Function name='Centered'/>
<Function name='CMod'/>
<Function name='XMod'/>
<Function name='MMod'/>
<Function name='Overhead'/>
<Function name='Incoming'/>
<Function name='Space'/>
<Function name='Hallway'/>
<Function name='Confusion'/>
<Function name='Cover'/>
<Function name='Cross'/>
<Function name='Dark'/>
<Function name='Dizzy'/>
<Function name='Distant'/>
<Function name='UsingReverse'/>
<Function name='DrainSetting'/>
<Function name='Drunk'/>
<Function name='Echo'/>
<Function name='Expand'/>
<Function name='FailSetting'/>
<Function name='Flip'/>
<Function name='Floored'/>
<Function name='GetReversePercentForColumn'/>
<Function name='GetStepAttacks'/>
<Function name='IsEasierForSongAndSteps'/>
<Function name='IsEasierForCourseAndTrail'/>
<Function name='Incoming'/>
<Function name='Hallway'/>
<Function name='Hidden'/>
<Function name='HiddenOffset'/>
<Function name='HoldRolls'/>
<Function name='Invert'/>
<Function name='Left'/>
<Function name='LifeSetting'/>
<Function name='Little'/>
<Function name='MaxScrollBPM'/>
<Function name='Mines'/>
<Function name='Mini'/>
<Function name='Mirror'/>
<Function name='MMod'/>
<Function name='MuteOnError'/>
<Function name='NoAttack'/>
<Function name='NoFakes'/>
<Function name='NoHands'/>
<Function name='NoHolds'/>
<Function name='NoJumps'/>
<Function name='NoLifts'/>
<Function name='NoMines'/>
<Function name='NoQuads'/>
<Function name='NoRolls'/>
<Function name='NoStretch'/>
<Function name='NoteSkin'/>
<Function name='Overhead'/>
<Function name='Passmark'/>
<Function name='Planted'/>
<Function name='PlayerAutoPlay'/>
<Function name='Quick'/>
<Function name='RandAttack'/>
<Function name='RandomSpeed'/>
<Function name='RandomVanish'/>
<Function name='Reverse'/>
<Function name='Right'/>
<Function name='Roll'/>
<Function name='ScrollBPM'/>
<Function name='ScrollSpeed'/>
<Function name='Shuffle'/>
<Function name='Skew'/>
<Function name='Skippy'/>
<Function name='SoftShuffle'/>
<Function name='Space'/>
<Function name='Split'/>
<Function name='Stealth'/>
<Function name='Stomp'/>
<Function name='Sudden'/>
<Function name='SuddenOffset'/>
<Function name='SuperShuffle'/>
<Function name='TimeSpacing'/>
<Function name='Tilt'/>
<Function name='Tiny'/>
<Function name='Tipsy'/>
<Function name='Tornado'/>
<Function name='TurnNone'/>
<Function name='Twirl'/>
<Function name='Twister'/>
<Function name='UsingReverse'/>
<Function name='Wave'/>
<Function name='Wide'/>
<Function name='XMod'/>
<Function name='Xmode'/>
</Class>
<Class name='PlayerStageStats'>
<Function name='FailPlayer'/>
@@ -1515,10 +1518,7 @@
<Function name='AssistClap'/>
<Function name='AssistMetronome'/>
<Function name='AutosyncSetting'/>
<Function name='BatteryLives'/>
<Function name='DrainSetting'/>
<Function name='Haste'/>
<Function name='LifeSetting'/>
<Function name='MusicRate'/>
<Function name='RandomBGOnly'/>
<Function name='SaveReplay'/>
+146 -149
View File
@@ -2989,117 +2989,101 @@ save yourself some time, copy this for undocumented things:
Enum type options are almost identical to bool type. They take and return an enum value.<br />
For brevity, the functions are only given a description if the option requires careful handling or does not follow the float or bool interfaces.<br />
</Description>
<Function name='Alternate' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='AttackMines' return='bool' arguments='bool value'> </Function>
<Function name='BatteryLives' return='int' arguments='int num'> </Function>
<Function name='Backwards' return='bool' arguments='bool value'> </Function>
<Function name='Beat' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Big' return='bool' arguments='bool value'> </Function>
<Function name='Blink' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Blind' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='BMRize' return='bool' arguments='bool value'> </Function>
<Function name='Boomerang' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Boost' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Brake' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Bumpy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Centered' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='CMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a CMod set, returns the value of that CMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the CMod to the value and disables any XMod or MMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.
</Function>
<Function name='Confusion' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Cover' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Cross' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Dark' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Dizzy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Distant' return='float, float' arguments='float value, float approach_speed'>
If the player is using Distant (zero skew and positive tilt), returns the value of tilt and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to value and skew to zero.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='DrainSetting' return= 'DrainType' arguments='DrainType type'> </Function>
<Function name='Drunk' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Echo' return='bool' arguments='bool value'> </Function>
<Function name='Expand' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='FailSetting' return='FailType' arguments='FailType'>
Sets the <Link class='ENUM' function='FailType' /> for the player, if the optional argument is provided. Returns the <Link class='ENUM' function='FailType' /> that was previously set.
</Function>
<Function name='Flip' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Floored' return='bool' arguments='bool value'> </Function>
<Function name='GetStepAttacks' return='bool' argument=''>
Returns true if step attacks or random attacks are enabled.
</Function>
<Function name='IsEasierForCourseAndTrail' return='bool' arguments='Course c, Trail t'>
Returns <code>true</code> if the current PlayerOptions makes the current Course/Trail easier.
</Function>
<Function name='IsEasierForSongAndSteps' return='bool' arguments='Song so, Steps st'>
Returns <code>true</code> if the current PlayerOptions makes the current Song/Steps easier.
</Function>
<Function name='TimeSpacing' return='float, float' arguments='float value, float approach_speed'>
TimeSpacing is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It controls whether the speed mod is in X mode or C mode. It should only be set to 0 or 1, and is only a float value to allow tweening between the two states.
<Function name='Hallway' return='float, float' arguments='float value, float approach_speed'>
If the player is using Hallway (zero skew and negative tilt), returns the value of tilt and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to negative value and skew to zero.<br />
Pass in a positive value for the familiar meaning of Hallway.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Hidden' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='HiddenOffset' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='HoldRolls' return='bool' arguments='bool value'> </Function>
<Function name='Incoming' return='float, float' arguments='float value, float approach_speed'>
If the player is using Incoming ((positive skew and negative tilt) or (negative skew and positive tilt)), returns the value of skew and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to negative value and skew to value.<br />
Pass in a positive value for the familiar meaning of Incoming.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Invert' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Left' return='bool' arguments='bool value'> </Function>
<Function name='LifeSetting' return='LifeType' arguments='LifeType type'> </Function>
<Function name='Little' return='bool' arguments='bool value'> </Function>
<Function name='MaxScrollBPM' return='float, float' arguments='float value, float approach_speed'>
MaxScrollBPM is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It is the setting for the MMod.<br />
MMods are not tweenable or settable on ScreenGameplay. Use XMods if you need such an effect.
</Function>
<Function name='ScrollSpeed' return='float, float' arguments='float value, float approach_speed'>
ScrollSpeed is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It is the setting for the XMod.
</Function>
<Function name='ScrollBPM' return='float, float' arguments='float value, float approach_speed'>
ScrollBPM is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It is the setting for the CMod.
</Function>
<Function name='Boost' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Brake' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Wave' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Expand' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Boomerang' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Drunk' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Dizzy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Confusion' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Mini' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tiny' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Flip' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Invert' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tornado' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tipsy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Bumpy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Beat' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Xmode' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Twirl' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Roll' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Hidden' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='HiddenOffset' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Sudden' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='SuddenOffset' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Stealth' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Blink' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='RandomVanish' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Reverse' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Split' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Alternate' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Cross' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Centered' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Dark' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Blind' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Cover' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='RandAttack' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='NoAttack' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='PlayerAutoPlay' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tilt' return='float, float' arguments='float value, float approach_speed'>
Tilt is one of the mods for controlling the perspective. Use Overhead, Distant, Incoming, Space, Distant, or Hallway for controlling the perspective in the old way.<br />
Tilt tilts the note field forward and back.
</Function>
<Function name='Skew' return='float, float' arguments='float value, float approach_speed'>
Skew is one of the mods for controlling the perspective. Use Overhead, Distant, Incoming, Space, Distant, or Hallway for controlling the perspective in the old way.<br />
Skew moves the vanishing point for the note field away from the center of the screen.<br />
Skew has no effect in single mode if Center1Player is true.<br />
Skew has no effect in double mode.<br />
</Function>
<Function name='Passmark' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='RandomSpeed' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='TurnNone' return='bool' arguments='bool value'> </Function>
<Function name='Mirror' return='bool' arguments='bool value'> </Function>
<Function name='Backwards' return='bool' arguments='bool value'> </Function>
<Function name='Left' return='bool' arguments='bool value'> </Function>
<Function name='Right' return='bool' arguments='bool value'> </Function>
<Function name='Shuffle' return='bool' arguments='bool value'> </Function>
<Function name='SoftShuffle' return='bool' arguments='bool value'> </Function>
<Function name='SuperShuffle' return='bool' arguments='bool value'> </Function>
<Function name='NoHolds' return='bool' arguments='bool value'> </Function>
<Function name='NoRolls' return='bool' arguments='bool value'> </Function>
<Function name='NoMines' return='bool' arguments='bool value'> </Function>
<Function name='Little' return='bool' arguments='bool value'> </Function>
<Function name='Wide' return='bool' arguments='bool value'> </Function>
<Function name='Big' return='bool' arguments='bool value'> </Function>
<Function name='Quick' return='bool' arguments='bool value'> </Function>
<Function name='BMRize' return='bool' arguments='bool value'> </Function>
<Function name='Skippy' return='bool' arguments='bool value'> </Function>
<Function name='Mines' return='bool' arguments='bool value'> </Function>
<Function name='AttackMines' return='bool' arguments='bool value'> </Function>
<Function name='Echo' return='bool' arguments='bool value'> </Function>
<Function name='Stomp' return='bool' arguments='bool value'> </Function>
<Function name='Planted' return='bool' arguments='bool value'> </Function>
<Function name='Floored' return='bool' arguments='bool value'> </Function>
<Function name='Twister' return='bool' arguments='bool value'> </Function>
<Function name='HoldRolls' return='bool' arguments='bool value'> </Function>
<Function name='Mini' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Mirror' return='bool' arguments='bool value'> </Function>
<Function name='MMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a MMod set, returns the value of that MMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the MMod to the value and disables any CMod or XMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.<br />
MMods are not tweenable or settable on ScreenGameplay. Use XMods if you need such an effect.
</Function>
<Function name='MuteOnError' return='bool' arguments='bool value'> </Function>
<Function name='NoAttack' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='NoFakes' return='bool' arguments='bool value'> </Function>
<Function name='NoHolds' return='bool' arguments='bool value'> </Function>
<Function name='NoJumps' return='bool' arguments='bool value'> </Function>
<Function name='NoHands' return='bool' arguments='bool value'> </Function>
<Function name='NoLifts' return='bool' arguments='bool value'> </Function>
<Function name='NoFakes' return='bool' arguments='bool value'> </Function>
<Function name='NoQuads' return='bool' arguments='bool value'> </Function>
<Function name='NoStretch' return='bool' arguments='bool value'> </Function>
<Function name='MuteOnError' return='bool' arguments='bool value'> </Function>
<Function name='UsingReverse' return='bool' arguments=''>
Returns <code>true</code> if the player is using reverse. (equivalent to <code>GetReverse() == 1.0</code>)
</Function>
<Function name='NoMines' return='bool' arguments='bool value'> </Function>
<Function name='NoRolls' return='bool' arguments='bool value'> </Function>
<Function name='NoteSkin' return='string, bool' arguments='string name'>
Sets the NoteSkin to the named noteskin, unless name is nil or the noteskin does not exist. Returns the name of the previous noteskin and whether the set attempt succeeded.<br />
Changing the noteskin during a song is not supported.<br />
@@ -3107,58 +3091,77 @@ save yourself some time, copy this for undocumented things:
note_name= options:NoteSkin() -- Sets note_name to the player's current noteskin.<br />
prev_note_name, succeeded= options:NoteSkin("cel") -- Sets prev_note_name to the noteskin the player had set, changes the current noteskin to "cel", sets succeeded to true if the the "cel" noteskin exists.<br />
</Function>
<Function name='FailSetting' return='FailType' arguments='FailType'>
Sets the <Link class='ENUM' function='FailType' /> for the player, if the optional argument is provided. Returns the <Link class='ENUM' function='FailType' /> that was previously set.
<Function name='Overhead' return='bool' arguments='bool'>
If the player is using Overhead (0 tilt, 0 skew), returns true.<br />
If true is passed, sets the tilt and skew to 0.
</Function>
<Function name='CMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a CMod set, returns the value of that CMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the CMod to the value and disables any XMod or MMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.
</Function>
<Function name='XMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a XMod set, returns the value of that XMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the XMod to the value and disables any CMod or MMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.
</Function>
<Function name='MMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a MMod set, returns the value of that MMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the MMod to the value and disables any CMod or XMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.<br />
MMods are not tweenable or settable on ScreenGameplay. Use XMods if you need such an effect.
</Function>
<Function name='Overhead' return='bool' arguments='bool'>
If the player is using Overhead (0 tilt, 0 skew), returns true.<br />
If true is passed, sets the tilt and skew to 0.
</Function>
<Function name='Incoming' return='float, float' arguments='float value, float approach_speed'>
If the player is using Incoming ((positive skew and negative tilt) or (negative skew and positive tilt)), returns the value of skew and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to negative value and skew to value.<br />
Pass in a positive value for the familiar meaning of Incoming.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Space' return='float, float' arguments='float value, float approach_speed'>
If the player is using Space ((positive skew and positive tilt) or (negative skew and negative tilt)), returns the value of skew and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to value and skew to value.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Hallway' return='float, float' arguments='float value, float approach_speed'>
If the player is using Hallway (zero skew and negative tilt), returns the value of tilt and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to negative value and skew to zero.<br />
Pass in a positive value for the familiar meaning of Hallway.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Distant' return='float, float' arguments='float value, float approach_speed'>
If the player is using Distant (zero skew and positive tilt), returns the value of tilt and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to value and skew to zero.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='GetStepAttacks' return='bool' argument=''>
Returns true if step attacks or random attacks are enabled.
</Function>
<Function name='Passmark' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Planted' return='bool' arguments='bool value'> </Function>
<Function name='PlayerAutoPlay' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Quick' return='bool' arguments='bool value'> </Function>
<Function name='RandAttack' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='RandomSpeed' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='RandomVanish' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Reverse' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Right' return='bool' arguments='bool value'> </Function>
<Function name='Roll' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='ScrollBPM' return='float, float' arguments='float value, float approach_speed'>
ScrollBPM is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It is the setting for the CMod.
</Function>
<Function name='ScrollSpeed' return='float, float' arguments='float value, float approach_speed'>
ScrollSpeed is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It is the setting for the XMod.
</Function>
<Function name='Shuffle' return='bool' arguments='bool value'> </Function>
<Function name='Skew' return='float, float' arguments='float value, float approach_speed'>
Skew is one of the mods for controlling the perspective. Use Overhead, Distant, Incoming, Space, Distant, or Hallway for controlling the perspective in the old way.<br />
Skew moves the vanishing point for the note field away from the center of the screen.<br />
Skew has no effect in single mode if Center1Player is true.<br />
Skew has no effect in double mode.<br />
</Function>
<Function name='Skippy' return='bool' arguments='bool value'> </Function>
<Function name='SoftShuffle' return='bool' arguments='bool value'> </Function>
<Function name='Space' return='float, float' arguments='float value, float approach_speed'>
If the player is using Space ((positive skew and positive tilt) or (negative skew and negative tilt)), returns the value of skew and its approach_speed.<br />
Returns nil otherwise.<br />
If the optional first argument is passed, sets tilt to value and skew to value.<br />
If the optional second argument is passed, sets the approach_speed for skew and tilt to it.
</Function>
<Function name='Split' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Stealth' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Stomp' return='bool' arguments='bool value'> </Function>
<Function name='Sudden' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='SuddenOffset' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='SuperShuffle' return='bool' arguments='bool value'> </Function>
<Function name='TimeSpacing' return='float, float' arguments='float value, float approach_speed'>
TimeSpacing is one of the variables for controlling the speed mod.<br />
Use CMod, XMod, or MMod to set the speed mod unless you have a good reason not to.<br />
It controls whether the speed mod is in X mode or C mode. It should only be set to 0 or 1, and is only a float value to allow tweening between the two states.
</Function>
<Function name='Tilt' return='float, float' arguments='float value, float approach_speed'>
Tilt is one of the mods for controlling the perspective. Use Overhead, Distant, Incoming, Space, Distant, or Hallway for controlling the perspective in the old way.<br />
Tilt tilts the note field forward and back.
</Function>
<Function name='Tiny' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tipsy' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Tornado' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='TurnNone' return='bool' arguments='bool value'> </Function>
<Function name='Twirl' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Twister' return='bool' arguments='bool value'> </Function>
<Function name='UsingReverse' return='bool' arguments=''>
Returns <code>true</code> if the player is using reverse. (equivalent to <code>GetReverse() == 1.0</code>)
</Function>
<Function name='Wave' return='float, float' arguments='float value, float approach_speed'> </Function>
<Function name='Wide' return='bool' arguments='bool value'> </Function>
<Function name='XMod' return='float, float' arguments='float value, float approach_speed'>
If the player has a XMod set, returns the value of that XMod and its associated approach speed. Returns nil otherwise.<br />
If the optional first argument is passed, sets the XMod to the value and disables any CMod or MMod that is set.<br />
If the optional second argument is passed, sets the speed at which the transition occurs.
</Function>
<Function name='Xmode' return='float, float' arguments='float value, float approach_speed'> </Function>
</Class>
<Class name='PlayerStageStats'>
<Function name='FailPlayer' return='bool' arguments=''>
@@ -4306,14 +4309,8 @@ save yourself some time, copy this for undocumented things:
<Description>
See the description for PlayerOptions. The functions follow the same design.
</Description>
<Function name='LifeSetting' return='LifeType' arguments='LifeType type'>
</Function>
<Function name='DrainSetting' return= 'DrainType' arguments='DrainType type'>
</Function>
<Function name='AutosyncSetting' return='AutosyncType' arguments='AutosyncType type'>
</Function>
<Function name='BatteryLives' return='int' arguments='int num'>
</Function>
<Function name='AssistClap' return='bool' arguments='bool b'>
</Function>
<Function name='AssistMetronome' return='bool' arguments='bool b'>
+4 -1
View File
@@ -672,6 +672,8 @@ MinesSubtractLives=1
HeldAddLives=0
# how many lives an unsuccessful hold will cost you.
LetGoSubtractLives=1
# this function returns how many lives to add when a song ends in course mode.
CourseSongRewardLives=function(life_meter, pn) if GAMESTATE:GetCurrentSteps(pn):GetMeter() >= 8 then return 2 end return 1 end
# How many lives trigger the "Danger" state.
DangerThreshold=1
@@ -2537,7 +2539,7 @@ Persp,4="mod,hallway;name,Hallway"
Persp,5="mod,distant;name,Distant"
# Song options
# LifeType="3;together"
# LifeType="3"
LifeType=(GAMESTATE:IsCourseMode() and 3 or 2)..";together"
LifeTypeDefault=""
LifeType,1="mod,bar;name,Bar"
@@ -3299,6 +3301,7 @@ UnpauseWithStart=true
InitialBackgroundBrightness=1.0
SecondsBetweenComments=10.0
ScoreKeeperClass=ScoreKeeperClass()
ForceImmediateFailForBattery=true
TickEarlySeconds=0
LightsMode="LightsMode_Gameplay"
SurvivalModOverride=true
+7 -4
View File
@@ -868,11 +868,14 @@ void GameCommand::ApplySelf( const vector<PlayerNumber> &vpns ) const
}
// HACK: Set life type to BATTERY just once here so it happens once and
// we don't override the user's changes if they back out.
if( GAMESTATE->m_PlayMode == PLAY_MODE_ONI &&
GAMESTATE->m_PlayMode != OldPlayMode &&
GAMESTATE->m_SongOptions.GetStage().m_LifeType == LifeType_Bar )
FOREACH_PlayerNumber(pn)
{
SO_GROUP_ASSIGN( GAMESTATE->m_SongOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery );
if(GAMESTATE->m_PlayMode == PLAY_MODE_ONI &&
GAMESTATE->m_PlayMode != OldPlayMode &&
GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions.GetStage().m_LifeType ==LifeType_Bar)
{
PO_GROUP_ASSIGN(GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery);
}
}
}
+1 -1
View File
@@ -4,7 +4,7 @@
#include "PlayerNumber.h"
#include "GameConstantsAndTypes.h"
#include "ActorFrame.h"
#include "SongOptions.h"
#include "PlayerOptions.h"
class PlayerState;
class PlayerStageStats;
+18 -19
View File
@@ -31,21 +31,6 @@ LifeMeterBar::LifeMeterBar()
m_pPlayerState = NULL;
DrainType dtype = GAMESTATE->m_SongOptions.GetStage().m_DrainType;
switch( dtype )
{
case DrainType_Normal:
m_fLifePercentage = INITIAL_VALUE;
break;
/* These types only go down, so they always start at full. */
case DrainType_NoRecover:
case DrainType_SuddenDeath:
m_fLifePercentage = 1.0f; break;
default:
FAIL_M(ssprintf("Invalid DrainType: %i", dtype));
}
const RString sType = "LifeMeterBar";
m_fPassingAlpha = 0;
@@ -97,6 +82,20 @@ void LifeMeterBar::Load( const PlayerState *pPlayerState, PlayerStageStats *pPla
PlayerNumber pn = pPlayerState->m_PlayerNumber;
DrainType dtype = pPlayerState->m_PlayerOptions.GetStage().m_DrainType;
switch( dtype )
{
case DrainType_Normal:
m_fLifePercentage = INITIAL_VALUE;
break;
/* These types only go down, so they always start at full. */
case DrainType_NoRecover:
case DrainType_SuddenDeath:
m_fLifePercentage = 1.0f; break;
default:
FAIL_M(ssprintf("Invalid DrainType: %i", dtype));
}
// Change life difficulty to really easy if merciful beginner on
m_bMercifulBeginnerInEffect =
GAMESTATE->m_PlayMode == PLAY_MODE_REGULAR &&
@@ -129,9 +128,9 @@ void LifeMeterBar::ChangeLife( TapNoteScore score )
if( IsHot() && fDeltaLife < 0 )
fDeltaLife = min( fDeltaLife, -0.10f ); // make it take a while to get back to "hot"
switch( GAMESTATE->m_SongOptions.GetSong().m_DrainType )
switch(m_pPlayerState->m_PlayerOptions.GetSong().m_DrainType)
{
DEFAULT_FAIL( GAMESTATE->m_SongOptions.GetSong().m_DrainType );
DEFAULT_FAIL(m_pPlayerState->m_PlayerOptions.GetSong().m_DrainType);
case DrainType_Normal:
break;
case DrainType_NoRecover:
@@ -151,7 +150,7 @@ void LifeMeterBar::ChangeLife( TapNoteScore score )
void LifeMeterBar::ChangeLife( HoldNoteScore score, TapNoteScore tscore )
{
float fDeltaLife=0.f;
DrainType dtype = GAMESTATE->m_SongOptions.GetSong().m_DrainType;
DrainType dtype = m_pPlayerState->m_PlayerOptions.GetSong().m_DrainType;
switch( dtype )
{
case DrainType_Normal:
@@ -219,7 +218,7 @@ void LifeMeterBar::ChangeLife( float fDeltaLife )
if( m_pPlayerStageStats->m_bFailed )
return;
switch( GAMESTATE->m_SongOptions.GetSong().m_DrainType )
switch(m_pPlayerState->m_PlayerOptions.GetSong().m_DrainType)
{
case DrainType_Normal:
case DrainType_NoRecover:
+28 -9
View File
@@ -9,7 +9,7 @@
LifeMeterBattery::LifeMeterBattery()
{
m_iLivesLeft = GAMESTATE->m_SongOptions.GetStage().m_iBatteryLives;
m_iLivesLeft= 4;
m_iTrailingLivesLeft = m_iLivesLeft;
m_soundGainLife.Load( THEME->GetPathS("LifeMeterBattery","gain") );
@@ -20,6 +20,9 @@ void LifeMeterBattery::Load( const PlayerState *pPlayerState, PlayerStageStats *
{
LifeMeter::Load( pPlayerState, pPlayerStageStats );
m_iLivesLeft = m_pPlayerState->m_PlayerOptions.GetStage().m_BatteryLives;
m_iTrailingLivesLeft = m_iLivesLeft;
const RString sType = "LifeMeterBattery";
PlayerNumber pn = pPlayerState->m_PlayerNumber;
@@ -30,6 +33,7 @@ void LifeMeterBattery::Load( const PlayerState *pPlayerState, PlayerStageStats *
MINES_SUBTRACT_LIVES.Load(sType, "MinesSubtractLives");
HELD_ADD_LIVES.Load(sType, "HeldAddLives");
LET_GO_SUBTRACT_LIVES.Load(sType, "LetGoSubtractLives");
COURSE_SONG_REWARD_LIVES.Load(sType, "CourseSongRewardLives");
LIVES_FORMAT.Load(sType, "NumLivesFormat");
@@ -80,7 +84,7 @@ void LifeMeterBattery::OnSongEnded()
if( m_pPlayerStageStats->m_bFailed || m_iLivesLeft == 0 )
return;
if( m_iLivesLeft < GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives )
if( m_iLivesLeft < m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives )
{
m_iTrailingLivesLeft = m_iLivesLeft;
PlayerNumber pn = m_pPlayerState->m_PlayerNumber;
@@ -89,8 +93,18 @@ void LifeMeterBattery::OnSongEnded()
if( pCourse && pCourse->m_vEntries[GAMESTATE->GetCourseSongIndex()].iGainLives > -1 )
m_iLivesLeft += pCourse->m_vEntries[GAMESTATE->GetCourseSongIndex()].iGainLives;
else
m_iLivesLeft += ( GAMESTATE->m_pCurSteps[pn]->GetMeter()>=8 ? 2 : 1 );
m_iLivesLeft = min( m_iLivesLeft, GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives );
{
Lua *L= LUA->Get();
COURSE_SONG_REWARD_LIVES.PushSelf(L);
PushSelf(L);
LuaHelpers::Push(L, pn);
RString error= "Error running CourseSongRewardLives callback: ";
LuaHelpers::RunScriptOnStack(L, error, 2, 1, true);
m_iLivesLeft += luaL_optnumber(L, -1, 0);
lua_settop(L, 0);
LUA->Release(L);
}
m_iLivesLeft = min( m_iLivesLeft, m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives );
if( m_iTrailingLivesLeft < m_iLivesLeft )
m_soundGainLife.Play();
@@ -202,7 +216,7 @@ bool LifeMeterBattery::IsInDanger() const
bool LifeMeterBattery::IsHot() const
{
return m_iLivesLeft == GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives;
return m_iLivesLeft == m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives;
}
bool LifeMeterBattery::IsFailing() const
@@ -212,14 +226,14 @@ bool LifeMeterBattery::IsFailing() const
float LifeMeterBattery::GetLife() const
{
if( !GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives )
if(!m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives)
return 1;
return float(m_iLivesLeft) / GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives;
return float(m_iLivesLeft) / m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives;
}
int LifeMeterBattery::GetRemainingLives() const
{
if( !GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives )
if( !m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives )
return 1;
return m_iLivesLeft;
@@ -235,6 +249,11 @@ void LifeMeterBattery::Refresh()
//update m_sprBattery
}
int LifeMeterBattery::GetTotalLives()
{
return m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives;
}
void LifeMeterBattery::Update( float fDeltaTime )
{
LifeMeter::Update( fDeltaTime );
@@ -248,7 +267,7 @@ class LunaLifeMeterBattery: public Luna<LifeMeterBattery>
{
public:
static int GetLivesLeft( T* p, lua_State *L ) { lua_pushnumber( L, p->GetLivesLeft() ); return 1; }
static int GetTotalLives( T* p, lua_State *L ) { lua_pushnumber( L, GAMESTATE->m_SongOptions.GetSong().m_iBatteryLives ); return 1; }
static int GetTotalLives( T* p, lua_State *L ) { lua_pushnumber(L, p->GetTotalLives()); return 1; }
static int ChangeLives( T* p, lua_State *L ) { p->ChangeLives(IArg(1)); return 0; }
LunaLifeMeterBattery()
+2
View File
@@ -32,6 +32,7 @@ public:
void Refresh();
int GetLivesLeft() { return m_iLivesLeft; }
int GetTotalLives();
void ChangeLives(int iLifeDiff);
// Lua
@@ -52,6 +53,7 @@ private:
ThemeMetric<int> MINES_SUBTRACT_LIVES;
ThemeMetric<int> HELD_ADD_LIVES;
ThemeMetric<int> LET_GO_SUBTRACT_LIVES;
ThemeMetric<LuaReference> COURSE_SONG_REWARD_LIVES;
ThemeMetric<RString> LIVES_FORMAT;
AutoActor m_sprFrame;
+30 -4
View File
@@ -1,6 +1,7 @@
#include "global.h"
#include "LifeMeterTime.h"
#include "ThemeManager.h"
#include "Song.h"
#include "Steps.h"
#include "ActorUtil.h"
#include "Course.h"
@@ -94,11 +95,36 @@ void LifeMeterTime::OnLoadSong()
if( GetLifeSeconds() <= 0 && GAMESTATE->GetCourseSongIndex() > 0 )
return;
Course* pCourse = GAMESTATE->m_pCurCourse;
ASSERT( pCourse != NULL );
float fOldLife = m_fLifeTotalLostSeconds;
float fGainSeconds = pCourse->m_vEntries[GAMESTATE->GetCourseSongIndex()].fGainSeconds;
float fGainSeconds = 0;
if(GAMESTATE->IsCourseMode())
{
Course* pCourse = GAMESTATE->m_pCurCourse;
ASSERT( pCourse != NULL );
fGainSeconds= pCourse->m_vEntries[GAMESTATE->GetCourseSongIndex()].fGainSeconds;
}
else
{
// Placeholderish, at least this way it won't crash when someone tries it
// out in non-course mode. -Kyz
Song* song= GAMESTATE->m_pCurSong;
ASSERT(song != NULL);
float song_len= song->m_fMusicLengthSeconds;
Steps* steps= GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber];
ASSERT(steps != NULL);
RadarValues radars= steps->GetRadarValues(m_pPlayerState->m_PlayerNumber);
float scorable_things= radars[RadarCategory_TapsAndHolds] +
radars[RadarCategory_Lifts];
if(g_fTimeMeterSecondsChange[SE_Held] > 0.0f)
{
scorable_things+= radars[RadarCategory_Holds] +
radars[RadarCategory_Rolls];
}
// Calculate the amount of time to give for the player to need 80% W1.
float gainable_score_time= scorable_things * g_fTimeMeterSecondsChange[SE_W1];
fGainSeconds= song_len - (gainable_score_time * INITIAL_VALUE);
}
if( MIN_LIFE_TIME > fGainSeconds )
fGainSeconds = MIN_LIFE_TIME;
m_fLifeTotalGainedSeconds += fGainSeconds;
+7
View File
@@ -102,6 +102,13 @@ Message::Message( const RString &s )
m_bBroadcast = false;
}
Message::Message(const MessageID id)
{
m_sName= MessageIDToString(id);
m_pParams = new LuaTable;
m_bBroadcast = false;
}
Message::Message( const RString &s, const LuaReference &params )
{
m_sName = s;
+1
View File
@@ -90,6 +90,7 @@ const RString& MessageIDToString( MessageID m );
struct Message
{
explicit Message( const RString &s );
explicit Message(const MessageID id);
Message( const RString &s, const LuaReference &params );
~Message();
+2 -2
View File
@@ -53,10 +53,10 @@
static int func_name(T* p, lua_State* L) \
{ \
DefaultNilArgs(L, 1); \
lua_pushnumber(L, p->m_i ## member); \
lua_pushnumber(L, p->m_ ## member); \
if(lua_isnumber(L, 1)) \
{ \
p->m_i ## member = IArg(1); \
p->m_ ## member = IArg(1); \
} \
return 1; \
}
+2 -2
View File
@@ -626,7 +626,7 @@ void Player::Load()
// TODO: Remove use of PlayerNumber.
PlayerNumber pn = m_pPlayerState->m_PlayerNumber;
bool bOniDead = GAMESTATE->m_SongOptions.GetStage().m_LifeType == LifeType_Battery &&
bool bOniDead = m_pPlayerState->m_PlayerOptions.GetStage().m_LifeType == LifeType_Battery &&
(m_pPlayerStageStats == NULL || m_pPlayerStageStats->m_bFailed);
/* The editor reuses Players ... so we really need to make sure everything
@@ -1776,7 +1776,7 @@ int Player::GetClosestNonEmptyRow( int iNoteRow, int iMaxRowsAhead, int iMaxRows
bool Player::IsOniDead() const
{
// If we're playing on oni and we've died, do nothing.
return GAMESTATE->m_SongOptions.GetCurrent().m_LifeType == LifeType_Battery && m_pPlayerStageStats && m_pPlayerStageStats->m_bFailed;
return m_pPlayerState->m_PlayerOptions.GetStage().m_LifeType == LifeType_Battery && m_pPlayerStageStats && m_pPlayerStageStats->m_bFailed;
}
void Player::Fret( int col, int row, const RageTimer &tm, bool bHeld, bool bRelease )
+67
View File
@@ -12,6 +12,24 @@
#include "CommonMetrics.h"
#include <float.h>
static const char *LifeTypeNames[] = {
"Bar",
"Battery",
"Time",
};
XToString( LifeType );
XToLocalizedString( LifeType );
LuaXType( LifeType );
static const char *DrainTypeNames[] = {
"Normal",
"NoRecover",
"SuddenDeath",
};
XToString( DrainType );
XToLocalizedString( DrainType );
LuaXType( DrainType );
void NextFloat( float fValues[], int size );
void NextBool( bool bValues[], int size );
@@ -31,6 +49,9 @@ static const float CMOD_DEFAULT= 200.0f;
void PlayerOptions::Init()
{
m_LifeType = LifeType_Bar;
m_DrainType = DrainType_Normal;
m_BatteryLives = 4;
m_bSetScrollSpeed = false;
m_fMaxScrollBPM = 0; m_SpeedfMaxScrollBPM = 1.0f;
m_fTimeSpacing = 0; m_SpeedfTimeSpacing = 1.0f;
@@ -64,6 +85,9 @@ void PlayerOptions::Approach( const PlayerOptions& other, float fDeltaSeconds )
#define DO_COPY( x ) \
x = other.x;
DO_COPY( m_LifeType );
DO_COPY( m_DrainType );
DO_COPY( m_BatteryLives );
APPROACH( fTimeSpacing );
APPROACH( fScrollSpeed );
APPROACH( fMaxScrollBPM );
@@ -120,6 +144,26 @@ void PlayerOptions::GetMods( vector<RString> &AddTo, bool bForceNoteSkin ) const
{
//RString sReturn;
switch(m_LifeType)
{
case LifeType_Bar:
switch(m_DrainType)
{
case DrainType_Normal: break;
case DrainType_NoRecover: AddTo.push_back("NoRecover"); break;
case DrainType_SuddenDeath: AddTo.push_back("SuddenDeath"); break;
}
break;
case LifeType_Battery:
AddTo.push_back(ssprintf("%dLives", m_BatteryLives));
break;
case LifeType_Time:
AddTo.push_back("LifeTime");
break;
default:
FAIL_M(ssprintf("Invalid LifeType: %i", m_LifeType));
}
if( !m_fTimeSpacing )
{
if( m_fMaxScrollBPM )
@@ -394,6 +438,17 @@ bool PlayerOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut
level= CMOD_DEFAULT;
SET_FLOAT(fScrollBPM)
}
else if( sBit == "life" || sBit == "lives" )
{
// level is a percentage for every other option, so multiply by 100. -Kyz
m_BatteryLives= level * 100.0f;
}
else if( sBit == "bar" ) { m_LifeType= LifeType_Bar; }
else if( sBit == "battery" ) { m_LifeType= LifeType_Battery; }
else if( sBit == "lifetime" ) { m_LifeType= LifeType_Time; }
else if( sBit == "norecover" || sBit == "power-drop" ) { m_DrainType= DrainType_NoRecover; }
else if( sBit == "suddendeath" || sBit == "death" ) { m_DrainType= DrainType_SuddenDeath; }
else if( sBit == "normal-drain" ) { m_DrainType= DrainType_Normal; }
else if( sBit == "boost" ) SET_FLOAT( fAccels[ACCEL_BOOST] )
else if( sBit == "brake" || sBit == "land" ) SET_FLOAT( fAccels[ACCEL_BRAKE] )
else if( sBit == "wave" ) SET_FLOAT( fAccels[ACCEL_WAVE] )
@@ -692,6 +747,9 @@ float PlayerOptions::GetReversePercentForColumn( int iCol ) const
bool PlayerOptions::operator==( const PlayerOptions &other ) const
{
#define COMPARE(x) { if( x != other.x ) return false; }
COMPARE(m_LifeType);
COMPARE(m_DrainType);
COMPARE(m_BatteryLives);
COMPARE(m_fTimeSpacing);
COMPARE(m_fScrollSpeed);
COMPARE(m_fScrollBPM);
@@ -893,6 +951,9 @@ void PlayerOptions::ResetPrefs( ResetPrefsType type )
case saved_prefs_invalid_for_course:
break;
}
CPY(m_LifeType);
CPY(m_DrainType);
CPY(m_BatteryLives);
CPY( m_fPerspectiveTilt );
CPY( m_bTransforms[TRANSFORM_NOHOLDS] );
@@ -936,6 +997,9 @@ public:
// Direct control functions, for themes that can handle it.
ENUM_INTERFACE(LifeSetting, LifeType, LifeType);
ENUM_INTERFACE(DrainSetting, DrainType, DrainType);
INT_INTERFACE(BatteryLives, BatteryLives);
FLOAT_INTERFACE(TimeSpacing, TimeSpacing, true);
FLOAT_INTERFACE(MaxScrollBPM, MaxScrollBPM, true);
FLOAT_INTERFACE(ScrollSpeed, ScrollSpeed, true);
@@ -1302,6 +1366,9 @@ public:
ADD_METHOD( IsEasierForSongAndSteps );
ADD_METHOD( IsEasierForCourseAndTrail );
ADD_METHOD(LifeSetting);
ADD_METHOD(DrainSetting);
ADD_METHOD(BatteryLives);
ADD_METHOD(TimeSpacing);
ADD_METHOD(MaxScrollBPM);
ADD_METHOD(ScrollSpeed);
+31 -1
View File
@@ -11,6 +11,31 @@ struct lua_State;
#include "GameConstantsAndTypes.h"
#include "PlayerNumber.h"
enum LifeType
{
LifeType_Bar,
LifeType_Battery,
LifeType_Time,
NUM_LifeType,
LifeType_Invalid
};
const RString& LifeTypeToString( LifeType cat );
const RString& LifeTypeToLocalizedString( LifeType cat );
LuaDeclareType( LifeType );
enum DrainType
{
DrainType_Normal,
DrainType_NoRecover,
DrainType_SuddenDeath,
NUM_DrainType,
DrainType_Invalid
};
const RString& DrainTypeToString( DrainType cat );
const RString& DrainTypeToLocalizedString( DrainType cat );
LuaDeclareType( DrainType );
/** @brief Per-player options that are not saved between sessions. */
class PlayerOptions
{
@@ -19,7 +44,9 @@ public:
* @brief Set up the PlayerOptions with some reasonable defaults.
*
* This code was taken from Init() to use proper initialization. */
PlayerOptions(): m_bSetScrollSpeed(false),
PlayerOptions(): m_LifeType(LifeType_Bar), m_DrainType(DrainType_Normal),
m_BatteryLives(4),
m_bSetScrollSpeed(false),
m_fTimeSpacing(0), m_SpeedfTimeSpacing(1.0f),
m_fMaxScrollBPM(0), m_SpeedfMaxScrollBPM(1.0f),
m_fScrollSpeed(1.0f), m_SpeedfScrollSpeed(1.0f),
@@ -154,6 +181,9 @@ public:
float GetReversePercentForColumn( int iCol ) const; // accounts for all Directions
LifeType m_LifeType;
DrainType m_DrainType; // only used with LifeBar
int m_BatteryLives;
/* All floats have a corresponding speed setting, which determines how fast
* PlayerOptions::Approach approaches. */
bool m_bSetScrollSpeed; // true if the scroll speed was set by FromString
+21 -2
View File
@@ -25,8 +25,12 @@ const float LESSON_PASS_THRESHOLD = 0.8f;
Grade GetGradeFromPercent( float fPercent );
void PlayerStageStats::Init()
void PlayerStageStats::InternalInit()
{
m_for_multiplayer= false;
m_player_number= PLAYER_1;
m_multiplayer_number= MultiPlayer_P1;
m_bPlayerCanAchieveFullCombo = true;
m_bJoined = false;
m_vpPossibleSteps.clear();
@@ -67,6 +71,18 @@ void PlayerStageStats::Init()
m_HighScore = HighScore();
}
void PlayerStageStats::Init(PlayerNumber pn)
{
m_for_multiplayer= false;
m_player_number= pn;
}
void PlayerStageStats::Init(MultiPlayer pn)
{
m_for_multiplayer= true;
m_multiplayer_number= pn;
}
void PlayerStageStats::AddStats( const PlayerStageStats& other )
{
m_bJoined = other.m_bJoined;
@@ -353,7 +369,10 @@ void PlayerStageStats::SetLifeRecordAt( float fLife, float fStepsSecond )
// fSecond will always be greater than any value already in the map.
m_fLifeRecord[fStepsSecond] = fLife;
MESSAGEMAN->Broadcast( Message_LifeMeterChangedP1 );
Message msg(static_cast<MessageID>(Message_LifeMeterChangedP1+m_player_number));
msg.SetParam("Life", fLife);
msg.SetParam("StepsSecond", fStepsSecond);
MESSAGEMAN->Broadcast(msg);
// Memory optimization:
// If we have three consecutive records A, B, and C all with the same fLife,
+8 -2
View File
@@ -13,8 +13,10 @@ class PlayerStageStats
{
public:
/** @brief Set up the PlayerStageStats with default values. */
PlayerStageStats() { Init(); }
void Init();
PlayerStageStats() { InternalInit(); }
void InternalInit();
void Init(PlayerNumber pn);
void Init(MultiPlayer pn);
/**
* @brief Add stats from one PlayerStageStats to another.
@@ -31,6 +33,10 @@ public:
int GetLessonScoreNeeded() const;
void ResetScoreForLesson();
bool m_for_multiplayer;
PlayerNumber m_player_number;
MultiPlayer m_multiplayer_number;
bool m_bJoined;
bool m_bPlayerCanAchieveFullCombo;
vector<Steps*> m_vpPossibleSteps;
+27 -21
View File
@@ -71,6 +71,7 @@
static ThemeMetric<float> INITIAL_BACKGROUND_BRIGHTNESS ("ScreenGameplay","InitialBackgroundBrightness");
static ThemeMetric<float> SECONDS_BETWEEN_COMMENTS ("ScreenGameplay","SecondsBetweenComments");
static ThemeMetric<RString> SCORE_KEEPER_CLASS ("ScreenGameplay","ScoreKeeperClass");
static ThemeMetric<bool> FORCE_IMMEDIATE_FAIL_FOR_BATTERY("ScreenGameplay", "ForceImmediateFailForBattery");
AutoScreenMessage( SM_PlayGo );
@@ -135,7 +136,7 @@ void PlayerInfo::Load( PlayerNumber pn, MultiPlayer mp, bool bShowNoteField, int
break;
case PLAY_MODE_ONI:
case PLAY_MODE_ENDLESS:
if( GAMESTATE->m_SongOptions.GetStage().m_LifeType == LifeType_Time )
if( GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions.GetStage().m_LifeType == LifeType_Time )
m_pPrimaryScoreDisplay = new ScoreDisplayLifeTime;
else
m_pPrimaryScoreDisplay = new ScoreDisplayOni;
@@ -573,7 +574,7 @@ void ScreenGameplay::Init()
if( !GAMESTATE->IsPlayerEnabled(pi->m_pn) && !SHOW_LIFE_METER_FOR_DISABLED_PLAYERS )
continue; // skip
pi->m_pLifeMeter = LifeMeter::MakeLifeMeter( GAMESTATE->m_SongOptions.GetStage().m_LifeType );
pi->m_pLifeMeter = LifeMeter::MakeLifeMeter( pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType );
pi->m_pLifeMeter->Load( pi->GetPlayerState(), pi->GetPlayerStageStats() );
pi->m_pLifeMeter->SetName( ssprintf("Life%s",pi->GetName().c_str()) );
LOAD_ALL_COMMANDS_AND_SET_XY( pi->m_pLifeMeter );
@@ -585,7 +586,7 @@ void ScreenGameplay::Init()
// not 100% sure of that. -freem
if( !GAMESTATE->IsPlayerEnabled(pi->m_pn) && SHOW_LIFE_METER_FOR_DISABLED_PLAYERS )
{
if(GAMESTATE->m_SongOptions.GetStage().m_LifeType == LifeType_Bar)
if(pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType == LifeType_Bar)
static_cast<LifeMeterBar*>(pi->m_pLifeMeter)->ChangeLife(-1.0f);
}
}
@@ -1095,12 +1096,16 @@ void ScreenGameplay::LoadNextSong()
// No need to do this here. We do it in SongFinished().
//GAMESTATE->RemoveAllActiveAttacks();
/* If we're in battery mode, force FailImmediate. We assume in Player::Step
* that failed players can't step. */
if( GAMESTATE->m_SongOptions.GetCurrent().m_LifeType == LifeType_Battery )
// Force immediate fail behavior changed to theme metric by Kyz.
if(FORCE_IMMEDIATE_FAIL_FOR_BATTERY)
{
FOREACH_EnabledPlayerInfo( m_vPlayerInfo, pi )
PO_GROUP_ASSIGN( pi->GetPlayerState()->m_PlayerOptions, ModsLevel_Song, m_FailType, FailType_Immediate );
{
if(pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType == LifeType_Battery)
{
PO_GROUP_ASSIGN(pi->GetPlayerState()->m_PlayerOptions, ModsLevel_Song, m_FailType, FailType_Immediate);
}
}
}
m_textSongOptions.SetText( GAMESTATE->m_SongOptions.GetCurrent().GetString() );
@@ -1133,10 +1138,10 @@ void ScreenGameplay::LoadNextSong()
// reset oni game over graphic
SET_XY_AND_ON_COMMAND( pi->m_sprOniGameOver );
if( GAMESTATE->m_SongOptions.GetCurrent().m_LifeType==LifeType_Battery && pi->GetPlayerStageStats()->m_bFailed ) // already failed
if(pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType==LifeType_Battery && pi->GetPlayerStageStats()->m_bFailed) // already failed
pi->ShowOniGameOver();
if( GAMESTATE->m_SongOptions.GetCurrent().m_LifeType==LifeType_Bar && pi->m_pLifeMeter )
if(pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType==LifeType_Bar && pi->m_pLifeMeter )
pi->m_pLifeMeter->UpdateNonstopLifebar();
if( pi->m_pStepsDisplay )
@@ -1649,8 +1654,7 @@ void ScreenGameplay::Update( float fDeltaTime )
PlayerNumber pn = pi->GetStepsAndTrailIndex();
FailType ft = GAMESTATE->GetPlayerFailType( pi->GetPlayerState() );
LifeType lt = GAMESTATE->m_SongOptions.GetCurrent().m_LifeType;
LifeType lt = pi->GetPlayerState()->m_PlayerOptions.GetStage().m_LifeType;
if( ft == FailType_Off || ft == FailType_EndOfSong )
continue;
@@ -1683,12 +1687,7 @@ void ScreenGameplay::Update( float fDeltaTime )
if( !STATSMAN->m_CurStageStats.AllFailed() ) // if not the last one to fail
{
// kill them!
SOUND->PlayOnceFromDir( THEME->GetPathS(m_sName,"oni die") );
pi->ShowOniGameOver();
int tracks = pi->m_NoteData.GetNumTracks();
pi->m_NoteData.Init(); // remove all notes and scoring
pi->m_NoteData.SetNumTracks(tracks); // reset the number of tracks.
pi->m_pPlayer->FadeToFail(); // tell the NoteField to fade to white
FailFadeRemovePlayer(&*pi);
}
}
}
@@ -1823,10 +1822,7 @@ void ScreenGameplay::Update( float fDeltaTime )
if( !GAMESTATE->IsCpuPlayer(pi->m_pn) )
continue;
SOUND->PlayOnceFromDir( THEME->GetPathS(m_sName,"oni die") );
pi->ShowOniGameOver();
pi->m_NoteData.Init(); // remove all notes and scoring
pi->m_pPlayer->FadeToFail(); // tell the NoteField to fade to white
FailFadeRemovePlayer(&*pi);
}
}
}
@@ -1919,6 +1915,16 @@ void ScreenGameplay::Update( float fDeltaTime )
}
}
void ScreenGameplay::FailFadeRemovePlayer(PlayerInfo* pi)
{
SOUND->PlayOnceFromDir( THEME->GetPathS(m_sName,"oni die") );
pi->ShowOniGameOver();
int tracks = pi->m_NoteData.GetNumTracks();
pi->m_NoteData.Init(); // remove all notes and scoring
pi->m_NoteData.SetNumTracks(tracks); // reset the number of tracks.
pi->m_pPlayer->FadeToFail(); // tell the NoteField to fade to white
}
float ScreenGameplay::GetHasteRate()
{
return m_fCurrHasteRate;
+3
View File
@@ -172,6 +172,9 @@ public:
bool IsPaused() const { return m_bPaused; }
float GetHasteRate();
void FailFadeRemovePlayer(PlayerInfo* pi);
void FailFadeRemovePlayer(PlayerNumber pn);
vector<float> m_HasteTurningPoints; // Values at which the meaning of GAMESTATE->m_fHasteRate changes.
vector<float> m_HasteAddAmounts; // Amounts that are added to speed depending on what turning point has been passed.
float m_fHasteTimeBetweenUpdates; // Seconds between haste updates.
+1 -1
View File
@@ -197,8 +197,8 @@ void ScreenJukebox::Init()
PO_GROUP_ASSIGN( GAMESTATE->m_pPlayerState[p]->m_PlayerOptions, ModsLevel_Stage, m_fScrollSpeed, .25f );
PO_GROUP_ASSIGN( GAMESTATE->m_pPlayerState[p]->m_PlayerOptions, ModsLevel_Stage, m_fPerspectiveTilt, -1.0f );
PO_GROUP_ASSIGN_N( GAMESTATE->m_pPlayerState[p]->m_PlayerOptions, ModsLevel_Stage, m_fEffects, PlayerOptions::EFFECT_TINY, 1.0f );
PO_GROUP_ASSIGN( GAMESTATE->m_pPlayerState[p]->m_PlayerOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery );
}
SO_GROUP_ASSIGN( GAMESTATE->m_SongOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery );
}
FOREACH_EnabledPlayer( p )
+11 -3
View File
@@ -1254,11 +1254,19 @@ bool ScreenSelectMusic::MenuStart( const InputEventPlus &input )
// apply #LIVES
if( pCourse->m_iLives != -1 )
{
SO_GROUP_ASSIGN( GAMESTATE->m_SongOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery );
SO_GROUP_ASSIGN( GAMESTATE->m_SongOptions, ModsLevel_Stage, m_iBatteryLives, pCourse->m_iLives );
FOREACH_EnabledPlayer(pn)
{
PO_GROUP_ASSIGN(GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions, ModsLevel_Stage, m_LifeType, LifeType_Battery);
PO_GROUP_ASSIGN(GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions, ModsLevel_Stage, m_BatteryLives, pCourse->m_iLives);
}
}
if( pCourse->GetCourseType() == COURSE_TYPE_SURVIVAL)
SO_GROUP_ASSIGN( GAMESTATE->m_SongOptions, ModsLevel_Stage, m_LifeType, LifeType_Time );
{
FOREACH_EnabledPlayer(pn)
{
PO_GROUP_ASSIGN(GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions, ModsLevel_Stage, m_LifeType, LifeType_Time);
}
}
}
else
{
+1 -69
View File
@@ -4,24 +4,6 @@
#include "GameState.h"
#include "CommonMetrics.h"
static const char *LifeTypeNames[] = {
"Bar",
"Battery",
"Time",
};
XToString( LifeType );
XToLocalizedString( LifeType );
LuaXType( LifeType );
static const char *DrainTypeNames[] = {
"Normal",
"NoRecover",
"SuddenDeath",
};
XToString( DrainType );
XToLocalizedString( DrainType );
LuaXType( DrainType );
static const char *AutosyncTypeNames[] = {
"Off",
"Song",
@@ -43,9 +25,6 @@ LuaXType( SoundEffectType );
void SongOptions::Init()
{
m_LifeType = LifeType_Bar;
m_DrainType = DrainType_Normal;
m_iBatteryLives = 4;
m_bAssistClap = false;
m_bAssistMetronome = false;
m_fMusicRate = 1.0f;
@@ -67,9 +46,6 @@ void SongOptions::Approach( const SongOptions& other, float fDeltaSeconds )
#define DO_COPY( x ) \
x = other.x;
DO_COPY( m_LifeType );
DO_COPY( m_DrainType );
DO_COPY( m_iBatteryLives );
APPROACH( fMusicRate );
APPROACH( fHaste );
DO_COPY( m_bAssistClap );
@@ -96,27 +72,6 @@ static void AddPart( vector<RString> &AddTo, float level, RString name )
void SongOptions::GetMods( vector<RString> &AddTo ) const
{
switch( m_LifeType )
{
case LifeType_Bar:
switch( m_DrainType )
{
case DrainType_Normal: break;
case DrainType_NoRecover: AddTo.push_back("NoRecover"); break;
case DrainType_SuddenDeath: AddTo.push_back("SuddenDeath"); break;
}
break;
case LifeType_Battery:
AddTo.push_back( ssprintf( "%dLives", m_iBatteryLives ) );
break;
case LifeType_Time:
AddTo.push_back( "LifeTime" );
break;
default:
FAIL_M(ssprintf("Invalid LifeType: %i", m_LifeType));
}
if( m_fMusicRate != 1 )
{
RString s = ssprintf( "%2.2f", m_fMusicRate );
@@ -210,12 +165,6 @@ bool SongOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut )
}
matches.clear();
Regex lives("^([0-9]+) ?(lives|life)$");
if( lives.Compare(sBit, matches) )
{
m_iBatteryLives = StringToInt( matches[0] );
return true;
}
vector<RString> asParts;
split( sBit, " ", asParts, true );
@@ -227,12 +176,7 @@ bool SongOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut )
on = false;
}
if( sBit == "norecover" ) m_DrainType = DrainType_NoRecover;
else if( sBit == "suddendeath" || sBit == "death" ) m_DrainType = DrainType_SuddenDeath;
else if( sBit == "power-drop" ) m_DrainType = DrainType_NoRecover;
else if( sBit == "normal-drain" ) m_DrainType = DrainType_Normal;
else if( sBit == "clap" ) m_bAssistClap = on;
if( sBit == "clap" ) m_bAssistClap = on;
else if( sBit == "metronome" ) m_bAssistMetronome = on;
else if( sBit == "autosync" || sBit == "autosyncsong" ) m_AutosyncType = on ? AutosyncType_Song : AutosyncType_Off;
else if( sBit == "autosyncmachine" ) m_AutosyncType = on ? AutosyncType_Machine : AutosyncType_Off;
@@ -244,9 +188,6 @@ bool SongOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut )
else if( sBit == "randombg" ) m_bRandomBGOnly = on;
else if( sBit == "savescore" ) m_bSaveScore = on;
else if( sBit == "savereplay" ) m_bSaveReplay = on;
else if( sBit == "bar" ) m_LifeType = LifeType_Bar;
else if( sBit == "battery" ) m_LifeType = LifeType_Battery;
else if( sBit == "lifetime" ) m_LifeType = LifeType_Time;
else if( sBit == "haste" ) m_fHaste = on? 1.0f:0.0f;
else
return false;
@@ -257,9 +198,6 @@ bool SongOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut )
bool SongOptions::operator==( const SongOptions &other ) const
{
#define COMPARE(x) { if( x != other.x ) return false; }
COMPARE( m_LifeType );
COMPARE( m_DrainType );
COMPARE( m_iBatteryLives );
COMPARE( m_fMusicRate );
COMPARE( m_fHaste );
COMPARE( m_bAssistClap );
@@ -283,12 +221,9 @@ class LunaSongOptions: public Luna<SongOptions>
{
public:
ENUM_INTERFACE(LifeSetting, LifeType, LifeType);
ENUM_INTERFACE(DrainSetting, DrainType, DrainType);
ENUM_INTERFACE(AutosyncSetting, AutosyncType, AutosyncType);
//ENUM_INTERFACE(SoundEffectSetting, SoundEffectType, SoundEffectType);
// Broken, SoundEffectType_Speed disables rate mod, other settings have no effect. -Kyz
INT_INTERFACE(BatteryLives, BatteryLives);
BOOL_INTERFACE(AssistClap, AssistClap);
BOOL_INTERFACE(AssistMetronome, AssistMetronome);
BOOL_INTERFACE(StaticBackground, StaticBackground);
@@ -300,11 +235,8 @@ public:
LunaSongOptions()
{
ADD_METHOD(LifeSetting);
ADD_METHOD(DrainSetting);
ADD_METHOD(AutosyncSetting);
//ADD_METHOD(SoundEffectSetting);
ADD_METHOD(BatteryLives);
ADD_METHOD(AssistClap);
ADD_METHOD(AssistMetronome);
ADD_METHOD(StaticBackground);
+1 -29
View File
@@ -5,30 +5,6 @@
#include "EnumHelper.h"
enum LifeType
{
LifeType_Bar,
LifeType_Battery,
LifeType_Time,
NUM_LifeType,
LifeType_Invalid
};
const RString& LifeTypeToString( LifeType cat );
const RString& LifeTypeToLocalizedString( LifeType cat );
LuaDeclareType( LifeType );
enum DrainType
{
DrainType_Normal,
DrainType_NoRecover,
DrainType_SuddenDeath,
NUM_DrainType,
DrainType_Invalid
};
const RString& DrainTypeToString( DrainType cat );
const RString& DrainTypeToLocalizedString( DrainType cat );
LuaDeclareType( DrainType );
enum AutosyncType
{
AutosyncType_Off,
@@ -57,9 +33,6 @@ LuaDeclareType( SoundEffectType );
class SongOptions
{
public:
LifeType m_LifeType;
DrainType m_DrainType; // only used with LifeBar
int m_iBatteryLives;
bool m_bAssistClap;
bool m_bAssistMetronome;
float m_fMusicRate, m_SpeedfMusicRate;
@@ -76,8 +49,7 @@ public:
*
* This is taken from Init(), but uses the intended
* initialization lists. */
SongOptions(): m_LifeType(LifeType_Bar), m_DrainType(DrainType_Normal),
m_iBatteryLives(4), m_bAssistClap(false),
SongOptions(): m_bAssistClap(false),
m_bAssistMetronome(false), m_fMusicRate(1.0f),
m_SpeedfMusicRate(1.0f), m_fHaste(0.0f),
m_SpeedfHaste(1.0f), m_AutosyncType(AutosyncType_Off),
+8
View File
@@ -29,6 +29,14 @@ StageStats::StageStats()
m_fGameplaySeconds = 0;
m_fStepsSeconds = 0;
m_fMusicRate = 1;
FOREACH_PlayerNumber(pn)
{
m_player[pn].Init(pn);
}
FOREACH_MultiPlayer(pn)
{
m_multiPlayer[pn].Init(pn);
}
}
void StageStats::Init()