|
| | MultiGameLogic (Song *pSong, DataArray *pConfig, int nSeed) |
| | Construct the logic of a song and register the win_cheat script command.
|
| | ~MultiGameLogic () override |
| | Release the arbiter, restore the song speed, and unregister the cheat.
|
| bool | DispatchPriv (Message *pMsg) override |
| | Apply a packet from another console, or hand any other message to WorldLogic.
|
| int | GetTick () override |
| | Report the tick of the scheduler's clock.
|
| float | GetTime () override |
| | Report the time of the scheduler's clock.
|
| void | HandleInput (const RotateEvent &event) override |
| | Move a player to a neighbouring track and ask the arbiter to settle the move.
|
| void | SetPaused (bool bPaused, int nPad, int nReason) override |
| | Pause or resume, and show the pause dialog when pausing.
|
| bool | DeploySlowdown (Player *pPlayer) override |
| | Slow the song down for a player and, for a local player online, send a SlowdownPacket.
|
| bool | DeployFreestyle (Player *pPlayer) override |
| | Move a player to the freestyle track.
|
| bool | DeployBumper (Player *pPlayer) override |
| | Bump every other player on a player's track to a random other track.
|
| bool | DeployCrippler (Player *pPlayer) override |
| | Cripple every other player on a player's track.
|
| void | EndFreestyle (Player *pPlayer) override |
| | Move a player from the freestyle track back to a catch track.
|
| void | OnStart () override |
| | Enable the catch tracks, schedule the end of the song, and start the arbiter.
|
| void | OnFinish (bool bWon) override |
| | Celebrate a won song and collect or send the final score.
|
| void | OnBar (int nBar) override |
| | Update the score leader.
|
| void | OnSection () override |
| | Announce the completed stage while sections remain.
|
| void | OnPhraseCaptured (CatchTrack *pTrack, Player *pPlayer, int nBar, bool bAutocatch) override |
| | Update the score leader and, for a local player online, send a CapturePacket.
|
| void | OnPhraseEnded (Track *pTrack) override |
| | Act once a phrase of a track ended.
|
| void | OnPhraseMissed (Track *pTrack) override |
| | Act once a player missed a phrase.
|
| | GameLogic (Song *pSong, DataArray *pConfig, int nSeed) |
| | Construct the logic of a song.
|
| | ~GameLogic () override |
| | Stop the song and release the players and the tracks.
|
| void | Start () override |
| | Start the song, the tracks, the players, and the bar counting.
|
| void | Stop () override |
| | Stop the song, the tracks, and the players.
|
| bool | IsFinished () const override |
| | Report whether Stop() ran.
|
| int | HasQuit () const override |
| | Report mQuit.
|
| int | IsRestartRequested () const override |
| | Report whether the song is to start again once it ends.
|
| bool | IsFreestyling (int nPlayer) override |
| | Report whether a player is on the freestyle track.
|
| void | Poll () override |
| | Stop the song once the ending finished.
|
| float | GetProgress () override |
| | Report how far the song has played.
|
| void | HandleInput (const PlayNoteEvent &event) override |
| | Pass a note to the player.
|
| void | HandleInput (const BtnEvent< 3 > &event) override |
| | Pause the song from the controller of the player.
|
| void | HandleInput (const BtnEvent< 4 > &event) override |
| | Toggle the display option of a single controller and save it in the profile.
|
| void | HandleInput (const BtnEvent< 5 > &event) override |
| | Deploy the power-up of a player and log it.
|
| void | HandleInput (const ChangeSectionEvent &event) override |
| | Ignore the event.
|
| void | HandleInput (const BtnEvent< 9 > &event) override |
| | Ignore the event.
|
| void | HandleInput (const BtnEvent< 10 > &event) override |
| | Pass the button to the player.
|
| void | HandleInput (const BtnEvent< 8 > &event) override |
| | Ignore the event.
|
| void | HandleInput (const StickEvent< 2 > &event) override |
| | Pass the stick event to the player.
|
| void | HandleInput (const StickEvent< 6 > &event) override |
| | Pass the stick event to the player.
|
| bool | IsPlaying () const override |
| | Report whether the song is playing.
|
| bool | IsFreestyleTrackActive () const |
| | Report whether a player is on the freestyle track while the song plays.
|
| bool | HasPhraseThisBar () const |
| | Report whether a catch track has a phrase in the current bar.
|
| void | EndSong () |
| | Start the ending of the song.
|
| void | Finish (bool bWon) |
| | Stop the players at the end of the song.
|
| void | CapturePhrase (CatchTrack *pTrack, Player *pPlayer, int nBar, bool bStreak) |
| | Record the capture of a phrase and find the next phrase of each local player.
|
| void | ContinueStreak (Track *pTrack, int nBar, int nFromBar) |
| | Lengthen or reset the streak of the player of a track and find the next phrase.
|
| void | EndPhrase (Track *pTrack) |
| | Report the end of a phrase to the triggers and to OnPhraseEnded().
|
| void | MissPhrase (Track *pTrack) |
| | Record a missed phrase and report it to the triggers and to OnPhraseMissed().
|
| void | EnableNextTracks (int nBar) |
| | Enable the catch tracks of the next step of the song's enable order.
|
| void | EnterFreestyle (Player *pPlayer, bool bVictory) |
| | Move a player to the freestyle track.
|
| void | LeaveFreestyle (Player *pPlayer, int nTrack) |
| | Move a player from the freestyle track to a catch track and find the next phrase.
|
| void | StartSlowdown () |
| | Slow the song down.
|
| void | StopSlowdown () |
| | Return the song to its speed after StartSlowdown().
|
| bool | DeployAutocatcher (Player *pPlayer) |
| | Capture a phrase of the track of a player and pulse the controllers of every player on it.
|
| bool | DeployMultiplier (Player *pPlayer) |
| | Raise the multiplier of a player.
|
| | WorldLogic () |
| | Construct the logic and give the input of every controller to the world.
|
| | ~WorldLogic () override |
| | Release the logic.
|
| bool | DispatchPriv (Message *pMsg) override |
| | Pass a JoypadConnectionMsg to OnJoypadConnection() and ignore any other message.
|
| void | AllNotesOff () |
| | Silence every synthesiser channel.
|
| void | ScheduleControllerCheck () |
| | Pause the song again one tick from now when a controller is disconnected.
|
| int | OnJoypadConnection (JoypadConnectionMsg *pMsg) |
| | Pause the playing song when the controller of a player is disconnected.
|
| void * | operator new (size_t nSize) |
| | Allocate a sink from the pool heaps under the tag "MsgSink".
|
| void | operator delete (void *pBlock) |
| | Return a sink to the pool heaps.
|
| virtual | ~MsgSink () |
| virtual bool | Dispatch (Message *pMsg) |
| | Accept a message.
|
| void * | operator new (size_t size) |
| | Allocate from the main heap under the name MsgSink.
|
| void | operator delete (void *mem) |
| | Return memory to its heap.
|
| virtual | ~MsgSink () |
| | Destroy the sink.
|
| virtual bool | Dispatch (Message *msg) |
| | Handle a message.
|
|
| enum | State {
kStateIdle = 0
, kStatePlaying = 1
, kStatePaused = 2
, kStateSuspended = 3
,
kStateWon = 4
, kStateRunning = 5
, kStateEnding = 6
, kStateFinished = 7
} |
| | Values of mState. More...
|
| enum | Powerup {
kPowerupNone = 0
, kPowerupAutocatcher = 1
, kPowerupMultiplier = 2
, kPowerupSlowdown = 3
,
kPowerupFreestyle = 4
, kPowerupBumper = 5
, kPowerupCrippler = 6
, kPowerupCount = 7
} |
| | Kinds of power-up a player can hold. More...
|
| static int | FindDisconnectedPad () |
| | Find the controller of a player on this console that is disconnected.
|
| void | AssignTracks () |
| | Assign each player to a random catch track.
|
| void | ApplyFreestyleEffect (int nSet) |
| | Apply one effect set of the song.
|
| void | ShowPowerupText (const char *pszToken, int nPlayer) |
| | Show the localised text of a power-up.
|
| void | CreateTracks (int *pFreestyleType, int *pFreestyleInstrument) |
| | Create the catch tracks and the freestyle track of the song.
|
| void | TickBar () |
| | Count one bar, starting the next section when it begins.
|
| void | AdvanceSection () |
| | Start the next section.
|
| void | ClearNextPhrase (int nPlayer) |
| | Forget the next phrase of a player.
|
| void | FindNextPhrase (int nPlayer, int nTrack, int nFromBar) |
| | Find the first phrase on another catch track at or after a bar, and point the player at it.
|
| void | PlaceRandomPowerups () |
| | Place a random power-up in every bar of every catch track.
|
| void | PlacePowerups () |
| | Place the power-ups of every section in the busiest bars of the catch tracks.
|
| static int | GetControllerArgument (DataArray *pCommand) |
| | Report the controller argument of a script command.
|
| static void | OnAutocatcherCommand (DataArray *pCommand, void *pUserData) |
| | Deploy the autocatcher for a controller on the autocatcher script command.
|
| static void | OnMultiplierCommand (DataArray *pCommand, void *pUserData) |
| | Deploy the multiplier for a controller on the multiplier script command.
|
| static void | OnSlowCommand (DataArray *pCommand, void *pUserData) |
| | Turn the slowdown on or off outside an online game on the slow script command.
|
| static void | OnFreestyleCommand (DataArray *pCommand, void *pUserData) |
| | Deploy the freestyle for a controller on the freestyle script command.
|
| static void | OnFreestyleToggleCommand (DataArray *pCommand, void *pUserData) |
| | Move the player of a controller onto or off the freestyle track on the freestyle_toggle script command.
|
| static void | OnBumperCommand (DataArray *pCommand, void *pUserData) |
| | Deploy the bumper for a controller on the bumper script command.
|
| static void | OnCripplerCommand (DataArray *pCommand, void *pUserData) |
| | Deploy the crippler for a controller on the crippler script command.
|
| static void | OnPowerupCommand (DataArray *pCommand, void *pUserData) |
| | Give a power-up to the player of a controller on the powerup script command while the power-up cheat is on.
|
| Song * | mSong |
| int | mState |
| int | mPaused |
| int | mTicksPerBar |
| int | mNumBars |
| PlayMap * | mPlayMap |
| std::vector< std::unique_ptr< Player > > | mPlayers |
| std::vector< LocalPlayer * > | mLocalPlayers |
| std::vector< std::unique_ptr< CatchTrack > > | mCatchTracks |
| std::unique_ptr< FreestyleTrack > | mFreestyleTrack |
| std::unique_ptr< GameTrackSelector > | mTrackSelector |
| std::unique_ptr< SpeedRamp > | mSpeedRamp |
| int | mPhraseThisBar |
| int | mQuit |
| int | mReserved60 |
| int | mSectionStartBar |
| int | mNextSectionBar |
| int | mSection |
| WorldBeat | mWorldBeat |
| int | mSavedState |
| int | mReserved8c |
| int | mSlowdown |
| int | mNextEnableStep |
| std::vector< PlayerData > | mPlayerData |
| Ptr< Command > | mBarCmd |
| Ptr< Command > | mStopSlowdownCmd |
| Rand | mRand |
| int | mEndTick |
Rules of a song played by several players, on one console or online.
The RTTI records the class as deriving from GameLogic. The logic tracks the score leader, lets the bumper and crippler power-ups strike the other players on the same track, and ends the song with the results of every player. Online, every action of a local player is sent to the other consoles as a packet, every packet received is applied to the remote player it names, and the hosting console runs a NetArbiter and collects the final scores.