merge
+ support o2mania style BMS (7 keys) + move notes to autokeysound when reducing tracks
This commit is contained in:
@@ -9,6 +9,10 @@ change to JSON, but it is unsure if this will be done.
|
||||
Implement .ssc at your own risk.
|
||||
________________________________________________________________________________
|
||||
|
||||
[v0.53] - Wolfman2000
|
||||
* Added Fakes to the RadarCategories. Start parsing between versions.
|
||||
* Always write out the latest version to cache and hard drive.
|
||||
|
||||
[v0.52] - AJ
|
||||
* Add CHARTSTYLE tag to NoteData section.
|
||||
|
||||
@@ -17,4 +21,4 @@ ________________________________________________________________________________
|
||||
* Limit VERSION tag to two decimal places.
|
||||
|
||||
[v0.5] - Wolfman2000
|
||||
* Initial MSD-based version.
|
||||
* Initial MSD-based version.
|
||||
|
||||
@@ -13,6 +13,32 @@ _____________________________________________________________________________
|
||||
sm-ssc v1.2.3 | 2011022?
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
20110228
|
||||
--------
|
||||
* Add Fakes to the RadarCategories. [Wolfman2000]
|
||||
* [ScreenEdit] Display the number of Lifts and Fakes in a stepchart in the
|
||||
editor. These use metrics, so the lines can be made empty in themes that
|
||||
require them. [Wolfman2000]
|
||||
* [ArrowEffects] Allow for dizzy hold heads. Again, enable at your own risk.
|
||||
[Wolfman2000]
|
||||
* [StepsDisplay] Allow for displaying the chart artist in a separate field.
|
||||
This defaults to false for the moment. [Wolfman2000]
|
||||
* [PlayerOptions, NoteDataUtil] Add transform mods for removing lifts and
|
||||
fakes from the Notedata. This mods can disqualify of course. [Wolfman2000]
|
||||
|
||||
20110227
|
||||
--------
|
||||
* [PlayerState] The old GetPlayerOptions() binding is now GetPlayerOptionsString().
|
||||
There is a new GetPlayerOptions() binding that gets the PlayerOptions object,
|
||||
which has a GetNoteSkin() binding (and hopefully more in the future). [AJ]
|
||||
|
||||
20110226
|
||||
--------
|
||||
* [ScreenOptionsToggleSongs] The structure of this screen has now changed.
|
||||
Before, it contained the entire list of songs. Now, the main page
|
||||
(ScreenOptionsToggleSongs) holds the groups, and a sub-page
|
||||
(ScreenOptionsToggleSongsSubPage) holds the songs in each group. [AJ]
|
||||
|
||||
20110225
|
||||
--------
|
||||
* Add lifts and fakes to all Pump noteskins. [Daisuke Master, Wolfman2000]
|
||||
|
||||
@@ -412,6 +412,7 @@ ScoreDisplay=ScoreDisplay
|
||||
Scoreboard=Enables scoreboard
|
||||
ScoringType=Defines which scoring method to use.
|
||||
Scroll=Scroll
|
||||
Select Group=Toggle Songs in this Group.
|
||||
Select Profile=Choose a profile
|
||||
Server=Start Local Server
|
||||
Servers=Servers
|
||||
@@ -442,6 +443,7 @@ Test Lights=Test the responsiveness of connected lights.
|
||||
TextureColorDepth=Choose the color depth of textures. 32 bit textures use more memory, but look nicer.
|
||||
Theme=Choose from this list of installed theme packs.
|
||||
TimingWindowScale=Increase this value to cause your steps to be judged more strictly (i.e. shrink the timing window).
|
||||
Toggle Song=Toggle Song
|
||||
Turn=Turn
|
||||
Transfer Edits to USB=Transfer Edits to USB
|
||||
Transfer Edits from USB=Transfer Edits from USB
|
||||
@@ -474,7 +476,8 @@ Play=Play the course.
|
||||
Save=Save the course.
|
||||
Edit Course=Edit Course contents.
|
||||
Shuffle=Shuffle the songs around.
|
||||
|
||||
#
|
||||
GamePrefDefaultFail=Immediate fail causes a player to die when their life bar reaches 0. ImmediateContinue allows you to continue playing afterwards.
|
||||
[OptionNames]
|
||||
0=0
|
||||
0.25x=0.25x
|
||||
@@ -656,6 +659,8 @@ NoRolls=No Rolls
|
||||
NoQuads=No Quads
|
||||
NoRecover=No Recover
|
||||
NoStretch=No Stretch
|
||||
NoLifts=No Lifts
|
||||
NoFakes=No Fakes
|
||||
None=None
|
||||
Normal=Normal
|
||||
Num Songs=Num Songs
|
||||
@@ -1034,7 +1039,8 @@ Max Minutes=Max Minutes
|
||||
Play=Play
|
||||
Edit Course=Edit Course
|
||||
Shuffle=Shuffle
|
||||
|
||||
#
|
||||
GamePrefDefaultFail=Default Fail Type
|
||||
[PaneDisplay]
|
||||
Steps=Steps
|
||||
Holds=Holds
|
||||
@@ -1242,6 +1248,8 @@ Hands=Hands
|
||||
Holds=Holds
|
||||
Mines=Mines
|
||||
Rolls=Rolls
|
||||
Lifts=Lifts
|
||||
Fakes=Fakes
|
||||
Beat 0 offset=Beat 0 offset
|
||||
Preview Start=Preview Start
|
||||
Preview Length=Preview Length
|
||||
|
||||
@@ -123,6 +123,22 @@ function table.deviation( t )
|
||||
end
|
||||
return offset
|
||||
end
|
||||
-- See if this exists
|
||||
function table.search( t, sFind )
|
||||
for i=1,#t do
|
||||
if t[i] == sFind then
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
-- Retreive the entry that has this
|
||||
function table.find( t, sFind )
|
||||
for i=1,#t do
|
||||
if t[i] == sFind then
|
||||
return i
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function round(val, decimal)
|
||||
if (decimal) then
|
||||
|
||||
@@ -263,7 +263,7 @@ function SpeedMods()
|
||||
Choices = GetSpeedMods(),
|
||||
|
||||
LoadSelections = function(self, list, pn)
|
||||
local pMods = GAMESTATE:GetPlayerState(pn):GetPlayerOptions("ModsLevel_Preferred")
|
||||
local pMods = GAMESTATE:GetPlayerState(pn):GetPlayerOptionsString("ModsLevel_Preferred")
|
||||
for i = 1,table.getn(self.Choices) do
|
||||
if string.find(pMods, self.Choices[i]) then
|
||||
list[i] = true
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
-- sm-ssc Default Theme Preferences Handler
|
||||
function InitGamePrefs()
|
||||
local Prefs =
|
||||
local Prefs =
|
||||
{
|
||||
{ "DefaultFail", "Immediate" },
|
||||
};
|
||||
|
||||
local BPrefs =
|
||||
{
|
||||
{ "AutoSetStyle", false },
|
||||
{ "NotePosition", true },
|
||||
@@ -9,6 +14,12 @@ function InitGamePrefs()
|
||||
};
|
||||
|
||||
for idx,pref in ipairs(Prefs) do
|
||||
if GetGamePref( pref[1] ) == nil then
|
||||
SetGamePref( pref[1], pref[2] );
|
||||
end;
|
||||
end;
|
||||
|
||||
for idx,pref in ipairs(BPrefs) do
|
||||
if GetGamePrefB( pref[1] ) == nil then
|
||||
SetGamePref( pref[1], pref[2] );
|
||||
end;
|
||||
@@ -456,3 +467,43 @@ function GamePrefNotePosition()
|
||||
setmetatable( t, t );
|
||||
return t;
|
||||
end
|
||||
|
||||
function GamePrefDefaultFail()
|
||||
local t = {
|
||||
Name = "GamePrefDefaultFail";
|
||||
LayoutType = "ShowAllInRow";
|
||||
SelectType = "SelectOne";
|
||||
OneChoiceForAllPlayers = true;
|
||||
ExportOnChange = false;
|
||||
Choices = { "Immediate","ImmediateContinue", "AtEnd", "Off" };
|
||||
LoadSelections = function(self, list, pn)
|
||||
if ReadGamePrefFromFile("DefaultFail") ~= nil then
|
||||
if GetGamePref("DefaultFail") then
|
||||
list[table.find( list, GetGamePref("DefaultFail") )] = true;
|
||||
else
|
||||
list[1] = true;
|
||||
end;
|
||||
else
|
||||
WriteGamePrefToFile("DefaultFail","Immediate");
|
||||
list[1] = true;
|
||||
end;
|
||||
end;
|
||||
SaveSelections = function(self, list, pn)
|
||||
-- This is so stupid.
|
||||
local tChoices = { "Immediate","ImmediateContinue", "AtEnd", "Off" };
|
||||
local val;
|
||||
for i=1,#list do
|
||||
if list[i] then
|
||||
val = i;
|
||||
else
|
||||
val = 1;
|
||||
end
|
||||
end
|
||||
WriteGamePrefToFile("DefaultFail",tChoices[val]);
|
||||
MESSAGEMAN:Broadcast("PreferenceSet", { Message == "Set Preference" } );
|
||||
THEME:ReloadMetrics();
|
||||
end;
|
||||
};
|
||||
setmetatable( t, t );
|
||||
return t;
|
||||
end
|
||||
|
||||
@@ -173,6 +173,7 @@ BeatOffsetHeight=15
|
||||
BeatPIHeight=2
|
||||
MiniPercentBase=0.5
|
||||
MiniPercentGate=1
|
||||
DizzyHoldHeads=false
|
||||
QuantizeArrowYPosition=false
|
||||
|
||||
[Background]
|
||||
@@ -1259,6 +1260,13 @@ DescriptionOnCommand=
|
||||
DescriptionOffCommand=
|
||||
DescriptionSetCommand=
|
||||
#
|
||||
ShowCredit=false
|
||||
CreditX=0
|
||||
CreditY=0
|
||||
CreditOnCommand=
|
||||
CreditOffCommand=
|
||||
CreditSetCommand=
|
||||
#
|
||||
ShowAutogen=false
|
||||
AutogenSetCommand=
|
||||
#
|
||||
@@ -2047,6 +2055,11 @@ DescriptionX=-10
|
||||
DescriptionY=0
|
||||
DescriptionOnCommand=shadowlength,0;uppercase,true;
|
||||
DescriptionSetCommand=%function(self,param) if param.CustomDifficulty then self:diffuse(CustomDifficultyToLightColor(param.CustomDifficulty)); self:strokecolor(CustomDifficultyToDarkColor(param.CustomDifficulty)); end end
|
||||
ShowCredit=false
|
||||
CreditX=0
|
||||
CreditY=0
|
||||
CreditOnCommand=
|
||||
CreditSetCommand=
|
||||
ShowAutogen=true
|
||||
AutogenX=40
|
||||
AutogenY=0
|
||||
@@ -2279,14 +2292,16 @@ Insert,5="mod,skippy;name,Skippy"
|
||||
Insert,6="mod,echo;name,Echo"
|
||||
Insert,7="mod,stomp;name,Stomp"
|
||||
|
||||
Remove="6;selectmultiple"
|
||||
RemoveDefault="mod,no little,no nojumps,no nohands,no noquads,no nostretch,no norolls"
|
||||
Remove="8;selectmultiple"
|
||||
RemoveDefault="mod,no little,no nojumps,no nohands,no noquads,no nostretch,no norolls,no nolifts,no nofakes"
|
||||
Remove,1="mod,little;name,Little"
|
||||
Remove,2="mod,nojumps;name,NoJumps"
|
||||
Remove,3="mod,nohands;name,NoHands"
|
||||
Remove,4="mod,noquads;name,NoQuads"
|
||||
Remove,5="mod,nostretch;name,NoStretch"
|
||||
Remove,6="mod,norolls;name,NoRolls"
|
||||
Remove,7="mod,nolifts;name,NoLifts"
|
||||
Remove,8="mod,nofakes;name,NoFakes"
|
||||
|
||||
# Insert="8"
|
||||
# InsertDefault="mod,no little,no wide,no big,no quick,no skippy,no echo,no stomp"
|
||||
@@ -2732,7 +2747,8 @@ LineNames="2,3,4,8,11,13,14,15,16,28,29,30"
|
||||
Line2="conf,ScoringType"
|
||||
Line3="conf,TimingWindowScale"
|
||||
Line4="conf,LifeDifficulty"
|
||||
Line8="conf,DefaultFailType"
|
||||
Line8="lua,GamePrefDefaultFail()"
|
||||
# Line8="conf,DefaultFailType"
|
||||
Line11="conf,AllowW1"
|
||||
Line13="conf,HiddenSongs"
|
||||
Line14="conf,EasterEggs"
|
||||
@@ -3363,6 +3379,7 @@ CategoryZoom=0.7
|
||||
CharsZoomSmall=1.0
|
||||
CharsZoomLarge=1.5
|
||||
CharsSpacingY=40
|
||||
CharsChoices=" ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
||||
ScrollingCharsCommand=diffuse,0.6,0.8,0.8,1
|
||||
SelectedCharsCommand=diffuse,0.8,1,1,1
|
||||
ReceptorArrowsY=SCREEN_CENTER_Y-140
|
||||
@@ -3629,6 +3646,8 @@ NumHoldsFormat="%s: %d\n"
|
||||
NumMinesFormat="%s: %d\n"
|
||||
NumHandsFormat="%s: %d\n"
|
||||
NumRollsFormat="%s: %d\n"
|
||||
NumLiftsFormat="%s: %d\n"
|
||||
NumFakesFormat="%s: %d\n"
|
||||
Beat0OffsetFormat="%s:\n %.5f secs\n"
|
||||
PreviewStartFormat="%s:\n %.5f secs\n"
|
||||
PreviewLengthFormat="%s:\n %.5f secs\n"
|
||||
|
||||
@@ -33,7 +33,7 @@ local function CreateStats( pnPlayer )
|
||||
--
|
||||
local t = Def.ActorFrame {};
|
||||
t[#t+1] = Def.ActorFrame {
|
||||
InitCommand=cmd(y,-16);
|
||||
InitCommand=cmd(y,-32);
|
||||
LoadActor(THEME:GetPathG("ScreenTitleMenu","PreferenceFrame")) .. {
|
||||
InitCommand=cmd(zoom,0.875;diffuse,PlayerColor( pnPlayer ));
|
||||
};
|
||||
@@ -43,7 +43,7 @@ local function CreateStats( pnPlayer )
|
||||
aText .. { Text=string.format("%04i",tValues["ITG_MAX"]); InitCommand=cmd(x,32;y,5;vertalign,bottom;zoom,0.5); };
|
||||
};
|
||||
t[#t+1] = Def.ActorFrame {
|
||||
InitCommand=cmd(y,16);
|
||||
InitCommand=cmd(y,-16);
|
||||
LoadActor(THEME:GetPathG("ScreenTitleMenu","PreferenceFrame")) .. {
|
||||
InitCommand=cmd(zoom,0.875;diffuse,PlayerColor( pnPlayer ));
|
||||
};
|
||||
@@ -52,6 +52,14 @@ local function CreateStats( pnPlayer )
|
||||
aText .. { Text="/"; InitCommand=cmd(x,28;y,5;vertalign,bottom;zoom,0.5;diffusealpha,0.5); };
|
||||
aText .. { Text=string.format("%04i",tValues["MIGS_MAX"]); InitCommand=cmd(x,32;y,5;vertalign,bottom;zoom,0.5); };
|
||||
};
|
||||
t[#t+1] = Def.ActorFrame {
|
||||
InitCommand=cmd(y,0);
|
||||
LoadActor(THEME:GetPathG("ScreenTitleMenu","PreferenceFrame")) .. {
|
||||
InitCommand=cmd(zoom,0.875;diffuse,PlayerColor( pnPlayer ));
|
||||
};
|
||||
aLabel .. { Text="Signed:"; InitCommand=cmd(x,-64) };
|
||||
aText .. { Text=string.format( #(tPlayerData[PLAYER_1].SignedJudgments) ); InitCommand=cmd(x,-8;y,5;vertalign,bottom;zoom,0.675); };
|
||||
};
|
||||
return t
|
||||
end;
|
||||
local t = Def.ActorFrame {};
|
||||
|
||||
@@ -120,16 +120,16 @@ t[#t+1] = Def.ActorFrame {
|
||||
InitCommand=cmd(x,-128+16+8;y,-14+16*3);
|
||||
};
|
||||
-- Center
|
||||
CreatePaneDisplayItem( iPN, "MINES", 'RadarCategory_Mines' ) .. {
|
||||
CreatePaneDisplayItem( iPN, "HANDS", 'RadarCategory_Hands' ) .. {
|
||||
InitCommand=cmd(x,-128+16+8+74;y,-14);
|
||||
};
|
||||
CreatePaneDisplayItem( iPN, "HANDS", 'RadarCategory_Hands' ) .. {
|
||||
CreatePaneDisplayItem( iPN, "ROLLS", 'RadarCategory_Rolls' ) .. {
|
||||
InitCommand=cmd(x,-128+16+8+74;y,-14+16);
|
||||
};
|
||||
CreatePaneDisplayItem( iPN, "ROLLS", 'RadarCategory_Rolls' ) .. {
|
||||
CreatePaneDisplayItem( iPN, "LIFTS", 'RadarCategory_Lifts' ) .. {
|
||||
InitCommand=cmd(x,-128+16+8+74;y,-14+16*2);
|
||||
};
|
||||
CreatePaneDisplayItem( iPN, "LIFTS", 'RadarCategory_Lifts' ) .. {
|
||||
CreatePaneDisplayItem( iPN, "FAKES", 'RadarCategory_Fakes' ) .. {
|
||||
InitCommand=cmd(x,-128+16+8+74;y,-14+16*3);
|
||||
};
|
||||
-- Right
|
||||
|
||||
@@ -140,7 +140,7 @@ Warning10Command=diffuseshift;effectperiod,1;effectcolor2,Color("Red");effectcol
|
||||
|
||||
[MusicWheel]
|
||||
FadeSeconds=1
|
||||
SwitchSeconds=0.10
|
||||
SwitchSeconds=0.08
|
||||
RandomPicksLockedSongs=true
|
||||
RouletteSwitchSeconds=0.05
|
||||
RouletteSlowDownSwitches=5
|
||||
@@ -162,7 +162,7 @@ ScrollBarOnCommand=visible,false
|
||||
; self:rotationx( rotationx_radians * 180/math.pi ); --[[ to degrees end]] \
|
||||
; end;
|
||||
ItemTransformFunction=function(self,offsetFromCenter,itemIndex,numItems) self:x( (1-math.cos(offsetFromCenter/math.pi))*44 ); self:y( offsetFromCenter*46 ); end
|
||||
NumWheelItems=13
|
||||
NumWheelItems=11
|
||||
MusicWheelSortOnCommand=fov,90;
|
||||
MusicWheelSortOffCommand=fov,90;
|
||||
MusicWheelItemSortOnCommand=zoomy,0;bounceend,0.15;zoomy,1
|
||||
|
||||
@@ -3762,7 +3762,6 @@
|
||||
AACFBE3908E7D832005087FC /* InputEventPlus.h */,
|
||||
EE906F8012BF3AF800146C96 /* JsonUtil.cpp */,
|
||||
EE906F8112BF3AF800146C96 /* JsonUtil.h */,
|
||||
AA2FB638091212AF000FD574 /* LifeMeter.cpp */,
|
||||
AADD1CC2095C233E0088C9DF /* LocalizedString.cpp */,
|
||||
AADD1CC3095C233F0088C9DF /* LocalizedString.h */,
|
||||
AACFBE6108E7DBA8005087FC /* LuaExpressionTransform.cpp */,
|
||||
@@ -4000,6 +3999,7 @@
|
||||
AA6EFF1604770F63005F316C /* HoldJudgment.h */,
|
||||
AA6EFDE104770C79005F316C /* Inventory.cpp */,
|
||||
AA6EFDE204770C79005F316C /* Inventory.h */,
|
||||
AA2FB638091212AF000FD574 /* LifeMeter.cpp */,
|
||||
AA6EFF1A04770F63005F316C /* LifeMeter.h */,
|
||||
AA6EFF1B04770F63005F316C /* LifeMeterBar.cpp */,
|
||||
AA6EFF1C04770F63005F316C /* LifeMeterBar.h */,
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
#include "PlayerOptions.h"
|
||||
#include "PlayerState.h"
|
||||
|
||||
|
||||
ActiveAttackList::ActiveAttackList()
|
||||
{
|
||||
}
|
||||
@@ -40,7 +39,7 @@ void ActiveAttackList::Refresh()
|
||||
const Attack& attack = attacks[i];
|
||||
|
||||
if( !attack.bOn )
|
||||
continue; /* hasn't started yet */
|
||||
continue; // hasn't started yet
|
||||
if( !attack.bShowInAttackList )
|
||||
continue;
|
||||
|
||||
|
||||
+72
-13
@@ -64,6 +64,7 @@ LuaDeclareType( VertAlign );
|
||||
/** @brief The bottom vertical alignment constant. */
|
||||
#define align_bottom 1.0f
|
||||
|
||||
// ssc futures:
|
||||
/*
|
||||
enum EffectAction
|
||||
{
|
||||
@@ -113,13 +114,9 @@ public:
|
||||
* todo: split out into diffuse effects and translation effects, or
|
||||
* create an effect stack instead. -aj */
|
||||
enum Effect { no_effect,
|
||||
// diffuse effects
|
||||
diffuse_blink, diffuse_shift, diffuse_ramp,
|
||||
glow_blink, glow_shift, glow_ramp,
|
||||
rainbow,
|
||||
// translation effects
|
||||
wag, bounce, bob, pulse,
|
||||
spin, vibrate
|
||||
glow_blink, glow_shift, glow_ramp, rainbow,
|
||||
wag, bounce, bob, pulse, spin, vibrate
|
||||
};
|
||||
|
||||
/** @brief Various values an Actor's effect can be tied to. */
|
||||
@@ -136,7 +133,12 @@ public:
|
||||
NUM_CLOCKS
|
||||
};
|
||||
|
||||
///** @brief What type of Effect this is. */
|
||||
/*
|
||||
* @brief What type of Effect this is.
|
||||
*
|
||||
* This is an internal enum for checking if an effect can be run;
|
||||
* You can't have more than one of most EffectTypes in the Effect list. (You
|
||||
* might be able to have mutliple EffectType_Translates; not sure yet.) -aj */
|
||||
/*
|
||||
enum EffectType {
|
||||
EffectType_Diffuse,
|
||||
@@ -151,6 +153,7 @@ public:
|
||||
|
||||
// todo: use this instead of the Effect enum -aj
|
||||
/*
|
||||
// This is similar to Attributes in BitmapText as far as implementation.
|
||||
struct Effect
|
||||
{
|
||||
Effect() : m_Action(EffectAction_None), m_Type(EffectType_Invalid), m_fSecsIntoEffect(0),
|
||||
@@ -160,8 +163,9 @@ public:
|
||||
m_effectColor1(RageColor(1,1,1,1)), m_effectColor2(RageColor(1,1,1,1))
|
||||
{ }
|
||||
|
||||
EffectAction m_Action;
|
||||
EffectType m_Type; // diffuse, glow, or translate
|
||||
RString m_sName; // friendly name
|
||||
EffectAction m_Action; // replaces the old Effect enum
|
||||
EffectType m_Type; // determined by EffectAction
|
||||
float m_fSecsIntoEffect;
|
||||
float m_fEffectDelta;
|
||||
RageColor m_EffectColor1;
|
||||
@@ -177,6 +181,9 @@ public:
|
||||
};
|
||||
*/
|
||||
|
||||
/**
|
||||
* @brief The present state for the Tween.
|
||||
*/
|
||||
struct TweenState
|
||||
{
|
||||
void Init();
|
||||
@@ -207,6 +214,7 @@ public:
|
||||
RageColor diffuse[4];
|
||||
/** @brief The glow color for this TweenState. */
|
||||
RageColor glow;
|
||||
/** @brief A magical value that nobody really knows the use for. ;) */
|
||||
float aux;
|
||||
};
|
||||
|
||||
@@ -215,8 +223,13 @@ public:
|
||||
virtual void BeginDraw(); // pushes transform onto world matrix stack
|
||||
virtual void SetGlobalRenderStates(); // Actor should call this at beginning of their DrawPrimitives()
|
||||
virtual void SetTextureRenderStates(); // Actor should call this after setting a texture
|
||||
virtual void DrawPrimitives() {}; // Derivatives should override
|
||||
virtual void EndDraw(); // pops transform from world matrix stack
|
||||
/**
|
||||
* @brief Draw the primitives of the Actor.
|
||||
*
|
||||
* Derivative classes should override this function. */
|
||||
virtual void DrawPrimitives() {};
|
||||
/** @brief Pop the transform from the world matrix stack. */
|
||||
virtual void EndDraw();
|
||||
|
||||
// TODO: make Update non virtual and change all classes to override UpdateInternal
|
||||
// instead.
|
||||
@@ -241,10 +254,22 @@ public:
|
||||
* @brief Retrieve the Actor's parent.
|
||||
* @return the Actor's parent. */
|
||||
Actor *GetParent() { return m_pParent; }
|
||||
/**
|
||||
* @brief Retrieve the Actor's lineage.
|
||||
* @return the Actor's lineage. */
|
||||
RString GetLineage() const;
|
||||
|
||||
/**
|
||||
* @brief Retrieve the Actor's x position.
|
||||
* @return the Actor's x position. */
|
||||
float GetX() const { return m_current.pos.x; };
|
||||
/**
|
||||
* @brief Retrieve the Actor's y position.
|
||||
* @return the Actor's y position. */
|
||||
float GetY() const { return m_current.pos.y; };
|
||||
/**
|
||||
* @brief Retrieve the Actor's z position.
|
||||
* @return the Actor's z position. */
|
||||
float GetZ() const { return m_current.pos.z; };
|
||||
float GetDestX() const { return DestTweenState().pos.x; };
|
||||
float GetDestY() const { return DestTweenState().pos.y; };
|
||||
@@ -253,8 +278,17 @@ public:
|
||||
void SetY( float y ) { DestTweenState().pos.y = y; };
|
||||
void SetZ( float z ) { DestTweenState().pos.z = z; };
|
||||
void SetXY( float x, float y ) { DestTweenState().pos.x = x; DestTweenState().pos.y = y; };
|
||||
/**
|
||||
* @brief Add to the x position of this Actor.
|
||||
* @param x the amount to add to the Actor's x position. */
|
||||
void AddX( float x ) { SetX( GetDestX()+x ); }
|
||||
/**
|
||||
* @brief Add to the y position of this Actor.
|
||||
* @param y the amount to add to the Actor's y position. */
|
||||
void AddY( float y ) { SetY( GetDestY()+y ); }
|
||||
/**
|
||||
* @brief Add to the z position of this Actor.
|
||||
* @param z the amount to add to the Actor's z position. */
|
||||
void AddZ( float z ) { SetZ( GetDestZ()+z ); }
|
||||
|
||||
// height and width vary depending on zoom
|
||||
@@ -279,9 +313,23 @@ public:
|
||||
void SetBaseRotation( const RageVector3 &rot ) { m_baseRotation = rot; }
|
||||
virtual void SetBaseAlpha( float fAlpha ) { m_fBaseAlpha = fAlpha; }
|
||||
|
||||
float GetZoom() const { return DestTweenState().scale.x; } // not accurate in some cases
|
||||
/**
|
||||
* @brief Retrieve the general zoom factor, using the x coordinate of the Actor.
|
||||
*
|
||||
* Note that this is not accurate in some cases.
|
||||
* @return the zoom factor for the x coordinate of the Actor. */
|
||||
float GetZoom() const { return DestTweenState().scale.x; }
|
||||
/**
|
||||
* @brief Retrieve the zoom factor for the x coordinate of the Actor.
|
||||
* @return the zoom factor for the x coordinate of the Actor. */
|
||||
float GetZoomX() const { return DestTweenState().scale.x; }
|
||||
/**
|
||||
* @brief Retrieve the zoom factor for the y coordinate of the Actor.
|
||||
* @return the zoom factor for the y coordinate of the Actor. */
|
||||
float GetZoomY() const { return DestTweenState().scale.y; }
|
||||
/**
|
||||
* @brief Retrieve the zoom factor for the z coordinate of the Actor.
|
||||
* @return the zoom factor for the z coordinate of the Actor. */
|
||||
float GetZoomZ() const { return DestTweenState().scale.z; }
|
||||
void SetZoom( float zoom ) { DestTweenState().scale.x = zoom; DestTweenState().scale.y = zoom; DestTweenState().scale.z = zoom; }
|
||||
void SetZoomX( float zoom ) { DestTweenState().scale.x = zoom; }
|
||||
@@ -368,7 +416,12 @@ public:
|
||||
}
|
||||
const TweenState& DestTweenState() const { return const_cast<Actor*>(this)->DestTweenState(); }
|
||||
|
||||
enum StretchType { fit_inside, cover };
|
||||
/** @brief How do we handle stretching the Actor? */
|
||||
enum StretchType
|
||||
{
|
||||
fit_inside, /**< Have the Actor fit inside its parent, using the smaller zoom. */
|
||||
cover /**, Have the Actor cover its parent, using the larger zoom. */
|
||||
};
|
||||
|
||||
void ScaleToCover( const RectF &rect ) { ScaleTo( rect, cover ); }
|
||||
void ScaleToFitInside( const RectF &rect ) { ScaleTo( rect, fit_inside); };
|
||||
@@ -449,6 +502,9 @@ public:
|
||||
|
||||
|
||||
// other properties
|
||||
/**
|
||||
* @brief Determine if the Actor is visible at this time.
|
||||
* @return true if it's visible, false otherwise. */
|
||||
bool GetVisible() const { return m_bVisible; }
|
||||
void SetVisible( bool b ) { m_bVisible = b; }
|
||||
void SetShadowLength( float fLength ) { m_fShadowLengthX = fLength; m_fShadowLengthY = fLength; }
|
||||
@@ -506,9 +562,12 @@ public:
|
||||
HiddenPtr<LuaClass> m_pLuaInstance;
|
||||
|
||||
protected:
|
||||
/** @brief the name of the Actor. */
|
||||
RString m_sName;
|
||||
/** @brief the current parent of this Actor if it exists. */
|
||||
Actor *m_pParent;
|
||||
|
||||
/** @brief Some general information about the Tween. */
|
||||
struct TweenInfo
|
||||
{
|
||||
// counters for tweening
|
||||
|
||||
+9
-3
@@ -1,10 +1,9 @@
|
||||
/** @brief ActorFrame - A container for other actors. */
|
||||
|
||||
#ifndef ACTORFRAME_H
|
||||
#define ACTORFRAME_H
|
||||
|
||||
#include "Actor.h"
|
||||
|
||||
/** @brief A container for other Actors. */
|
||||
class ActorFrame : public Actor
|
||||
{
|
||||
public:
|
||||
@@ -17,7 +16,13 @@ public:
|
||||
void LoadFromNode( const XNode* pNode );
|
||||
virtual ActorFrame *Copy() const;
|
||||
|
||||
/**
|
||||
* @brief Add a new child to the ActorFrame.
|
||||
* @param pActor the new Actor to add. */
|
||||
virtual void AddChild( Actor *pActor );
|
||||
/**
|
||||
* @brief Remove the specified child from the ActorFrame.
|
||||
* @param pActor the Actor to remove. */
|
||||
virtual void RemoveChild( Actor *pActor );
|
||||
void TransferChildren( ActorFrame *pTo );
|
||||
Actor* GetChild( const RString &sName );
|
||||
@@ -93,6 +98,7 @@ public:
|
||||
protected:
|
||||
void LoadChildrenFromNode( const XNode* pNode );
|
||||
|
||||
/** @brief The children Actors used by the ActorFrame. */
|
||||
vector<Actor*> m_SubActors;
|
||||
bool m_bPropagateCommands;
|
||||
bool m_bDeleteChildren;
|
||||
@@ -118,7 +124,7 @@ protected:
|
||||
RageColor m_specularColor;
|
||||
RageVector3 m_lightDirection;
|
||||
};
|
||||
|
||||
/** @brief an ActorFrame that handles deleting children Actors automatically. */
|
||||
class ActorFrameAutoDeleteChildren : public ActorFrame
|
||||
{
|
||||
public:
|
||||
|
||||
@@ -46,6 +46,7 @@ private:
|
||||
bool m_bAlphaBuffer;
|
||||
bool m_bFloat;
|
||||
bool m_bPreserveTexture;
|
||||
/** @brief the name of this ActorFrameTexture. */
|
||||
RString m_sTextureName;
|
||||
};
|
||||
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
#include "Actor.h"
|
||||
|
||||
struct lua_State;
|
||||
/** @brief Rendrs another actor. */
|
||||
/** @brief Renders another actor. */
|
||||
class ActorProxy: public Actor
|
||||
{
|
||||
public:
|
||||
|
||||
+19
-7
@@ -1,5 +1,3 @@
|
||||
/* ActorScroller - ActorFrame that moves its children. */
|
||||
|
||||
#ifndef ActorScroller_H
|
||||
#define ActorScroller_H
|
||||
|
||||
@@ -7,7 +5,7 @@
|
||||
#include "Quad.h"
|
||||
class XNode;
|
||||
#include "LuaExpressionTransform.h"
|
||||
|
||||
/** @brief ActorFrame that moves its children. */
|
||||
class ActorScroller : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -56,9 +54,21 @@ protected:
|
||||
virtual void ShiftSubActors( int iDist );
|
||||
|
||||
int m_iNumItems;
|
||||
float m_fCurrentItem; // Item at center of list, usually between 0 and m_SubActors.size(), approaches destination
|
||||
/**
|
||||
* @brief the current item we are focused on.
|
||||
*
|
||||
* An item at the center of the list, usually between 0 and m_SubActors.size(),
|
||||
* will approach its destination.
|
||||
*
|
||||
* The above comment was paraphrased from what was here previously. It could use
|
||||
* some clearing up. -Wolfman2000 */
|
||||
float m_fCurrentItem;
|
||||
float m_fDestinationItem;
|
||||
float m_fSecondsPerItem; // <= 0 means don't scroll
|
||||
/**
|
||||
* @brief How many seconds are there per item?
|
||||
*
|
||||
* If this is less than zero, then we are not scrolling. */
|
||||
float m_fSecondsPerItem;
|
||||
float m_fSecondsPauseBetweenItems;
|
||||
float m_fNumItemsToDraw;
|
||||
int m_iFirstSubActorIndex;
|
||||
@@ -85,8 +95,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-5
@@ -1,11 +1,9 @@
|
||||
/* ActorSound - RageSound Actor interface. */
|
||||
|
||||
#ifndef ACTOR_SOUND_H
|
||||
#define ACTOR_SOUND_H
|
||||
|
||||
#include "Actor.h"
|
||||
#include "RageSound.h"
|
||||
|
||||
/** @brief RageSound Actor interface. */
|
||||
class ActorSound: public Actor
|
||||
{
|
||||
public:
|
||||
@@ -30,8 +28,10 @@ private:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2005 Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Glenn Maynard (c) 2005
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+20
-5
@@ -2,17 +2,30 @@
|
||||
#define ANNOUNCER_MANAGER_H
|
||||
|
||||
#include "RageTypes.h"
|
||||
|
||||
/** @brief The commentators who say seemlingly random things during gameplay. */
|
||||
class AnnouncerManager
|
||||
{
|
||||
public:
|
||||
AnnouncerManager();
|
||||
~AnnouncerManager();
|
||||
|
||||
/**
|
||||
* @brief Retrieve the announcer names.
|
||||
* @param AddTo the list of announcer names. */
|
||||
void GetAnnouncerNames( vector<RString>& AddTo );
|
||||
/**
|
||||
* @brief Determine if the specified announcer exists.
|
||||
* @param sAnnouncerName the announcer we're checking for.
|
||||
* @return true if it exists, false otherwise. */
|
||||
bool DoesAnnouncerExist( RString sAnnouncerName );
|
||||
/**
|
||||
* @brief Switch to a new specified announcer.
|
||||
* @param sNewAnnouncerName the new announcer the Player will be listening to. */
|
||||
void SwitchAnnouncer( RString sNewAnnouncerName );
|
||||
RString GetCurAnnouncerName() { return m_sCurAnnouncerName; };
|
||||
/**
|
||||
* @brief Retrieve the current announcer's name.
|
||||
* @return the current announcer's name. */
|
||||
RString GetCurAnnouncerName() const { return m_sCurAnnouncerName; };
|
||||
void NextAnnouncer();
|
||||
|
||||
RString GetPathTo( RString sFolderName );
|
||||
@@ -24,7 +37,7 @@ public:
|
||||
protected:
|
||||
static RString GetAnnouncerDirFromName( RString sAnnouncerName );
|
||||
RString GetPathTo( RString AnnouncerPath, RString sFolderName );
|
||||
|
||||
/** @brief the current announcer's name. */
|
||||
RString m_sCurAnnouncerName;
|
||||
};
|
||||
|
||||
@@ -33,8 +46,10 @@ extern AnnouncerManager* ANNOUNCER; // global and accessable from anywhere in ou
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+15
-5
@@ -15,7 +15,15 @@
|
||||
#include <float.h>
|
||||
|
||||
static ThemeMetric<float> ARROW_SPACING( "ArrowEffects", "ArrowSpacing" );
|
||||
static ThemeMetric<bool> QUANTIZE_ARROW_Y( "ArrowEffects", "QuantizeArrowYPosition");
|
||||
static ThemeMetric<bool> HIDDEN_SUDDEN_PAST_RECEPTOR( "ArrowEffects", "DrawHiddenNotesAfterReceptor");
|
||||
|
||||
/* For better or for worse, allow the themes to modify the various mod
|
||||
* effects for the different mods. In general, it is recommended to not
|
||||
* edit the default values and instead use percentage mods when changes
|
||||
* are wanted. Still, the option is available for those that want it.
|
||||
*
|
||||
* Is this a good idea? We'll find out. -aj & Wolfman2000 */
|
||||
static ThemeMetric<float> BLINK_MOD_FREQUENCY( "ArrowEffects", "BlinkModFrequency" );
|
||||
static ThemeMetric<float> BOOST_MOD_MIN_CLAMP( "ArrowEffects", "BoostModMinClamp" );
|
||||
static ThemeMetric<float> BOOST_MOD_MAX_CLAMP( "ArrowEffects", "BoostModMaxClamp" );
|
||||
@@ -50,7 +58,7 @@ static ThemeMetric<float> BEAT_OFFSET_HEIGHT( "ArrowEffects", "BeatOffsetHeight"
|
||||
static ThemeMetric<float> BEAT_PI_HEIGHT( "ArrowEffects", "BeatPIHeight" );
|
||||
static ThemeMetric<float> MINI_PERCENT_BASE( "ArrowEffects", "MiniPercentBase" );
|
||||
static ThemeMetric<float> MINI_PERCENT_GATE( "ArrowEffects", "MiniPercentGate" );
|
||||
static ThemeMetric<bool> QUANTIZE_ARROW_Y( "ArrowEffects", "QuantizeArrowYPosition");
|
||||
static ThemeMetric<bool> DIZZY_HOLD_HEADS( "ArrowEffects", "DizzyHoldHeads" );
|
||||
|
||||
static float GetNoteFieldHeight( const PlayerState* pPlayerState )
|
||||
{
|
||||
@@ -231,6 +239,8 @@ float ArrowEffects::GetYOffset( const PlayerState* pPlayerState, int iCol, float
|
||||
fYOffset += fYOffsetTimeSpacing * pPlayerState->m_PlayerOptions.GetCurrent().m_fTimeSpacing;
|
||||
}
|
||||
|
||||
// TODO: If we allow noteskins to have metricable row spacing
|
||||
// (per issue 24), edit this to reflect that. -aj
|
||||
fYOffset *= ARROW_SPACING;
|
||||
|
||||
// don't mess with the arrows after they've crossed 0
|
||||
@@ -287,8 +297,8 @@ float ArrowEffects::GetYOffset( const PlayerState* pPlayerState, int iCol, float
|
||||
seed = ((seed * 1664525u) + 1013904223u) & 0xFFFFFFFF;
|
||||
float fRandom = seed / 4294967296.0f;
|
||||
|
||||
/* Random speed always increases speed: a random speed of 10 indicates [1,11].
|
||||
* This keeps it consistent with other mods: 0 means no effect. */
|
||||
/* Random speed always increases speed: a random speed of 10 indicates
|
||||
* [1,11]. This keeps it consistent with other mods: 0 means no effect. */
|
||||
fScrollSpeed *=
|
||||
SCALE( fRandom,
|
||||
0.0f, 1.0f,
|
||||
@@ -498,8 +508,8 @@ float ArrowEffects::GetRotationZ( const PlayerState* pPlayerState, float fNoteBe
|
||||
if( fEffects[PlayerOptions::EFFECT_CONFUSION] != 0 )
|
||||
fRotation += ReceptorGetRotationZ( pPlayerState );
|
||||
|
||||
// Doesn't affect hold heads, unlike confusion
|
||||
if( fEffects[PlayerOptions::EFFECT_DIZZY] != 0 && !bIsHoldHead )
|
||||
// As usual, enable dizzy hold heads at your own risk. -Wolfman2000
|
||||
if( fEffects[PlayerOptions::EFFECT_DIZZY] != 0 && ( DIZZY_HOLD_HEADS || !bIsHoldHead ) )
|
||||
{
|
||||
const float fSongBeat = GAMESTATE->m_fSongBeatVisible;
|
||||
float fDizzyRotation = fNoteBeat - fSongBeat;
|
||||
|
||||
+31
-10
@@ -1,10 +1,8 @@
|
||||
/* ArrowEffects - Functions that return properties of arrows based on Style and PlayerOptions. */
|
||||
|
||||
#ifndef ARROWEFFECTS_H
|
||||
#define ARROWEFFECTS_H
|
||||
|
||||
class PlayerState;
|
||||
|
||||
/** @brief Functions that return properties of arrows based on Style and PlayerOptions. */
|
||||
class ArrowEffects
|
||||
{
|
||||
public:
|
||||
@@ -21,8 +19,16 @@ public:
|
||||
return GetYOffset( pPlayerState, iCol, fNoteBeat, fThrowAway, bThrowAway, bAbsolute );
|
||||
}
|
||||
|
||||
/* Actual display position, with reverse and post-reverse-effects factored in
|
||||
* (fYOffset -> YPos). */
|
||||
/**
|
||||
* @brief Retrieve the actual display position.
|
||||
*
|
||||
* In this case, reverse and post-reverse-effects are factored in (fYOffset -> YPos).
|
||||
* @param pPlayerState the Player's state in question, including mods.
|
||||
* @param iCol the specific arrow column.
|
||||
* @param fYOffset the original display position.
|
||||
* @param fYReverseOffsetPixels the amount offset due to reverse.
|
||||
* @param WithReverse a flag to see if the Reverse mod is on.
|
||||
* @return the actual display position. */
|
||||
static float GetYPos( const PlayerState* pPlayerState, int iCol, float fYOffset, float fYReverseOffsetPixels, bool WithReverse = true );
|
||||
|
||||
// Inverse of ArrowGetYPos (YPos -> fYOffset).
|
||||
@@ -37,14 +43,21 @@ public:
|
||||
// Due to the handling logic for holds on Twirl, we need to use an offset instead.
|
||||
// It's more intuitive for Roll to be based off offset, so use an offset there too.
|
||||
static float GetRotationX( const PlayerState* pPlayerState, float fYOffset );
|
||||
static float GetRotationY( const PlayerState *pPlayerState, float fYOffset );
|
||||
static float GetRotationY( const PlayerState* pPlayerState, float fYOffset );
|
||||
|
||||
// fXPos is a horizontal position in pixels relative to the center of the field.
|
||||
// This depends on the column of the arrow and possibly the Arrow effect and
|
||||
// fYPos (in the case of EFFECT_DRUNK).
|
||||
static float GetXPos( const PlayerState* pPlayerState, int iCol, float fYOffset );
|
||||
|
||||
// Z position; normally 0. Only visible in perspective modes.
|
||||
/**
|
||||
* @brief Retrieve the Z position.
|
||||
*
|
||||
* This is normally 0. This is only visible with perspective modes.
|
||||
* @param pPlayerState the Player's state, including the mods.
|
||||
* @param iCol the specific arrow column.
|
||||
* @param fYPos the Y position of the arrow.
|
||||
* @return the Z position. */
|
||||
static float GetZPos( const PlayerState* pPlayerState, int iCol, float fYPos );
|
||||
|
||||
// Enable this if any ZPos effects are enabled.
|
||||
@@ -58,7 +71,13 @@ public:
|
||||
// AppearanceType.
|
||||
static float GetGlow( const PlayerState* pPlayerState, int iCol, float fYPos, float fPercentFadeToFail, float fYReverseOffsetPixels, float fDrawDistanceBeforeTargetsPixels, float fFadeInPercentOfDrawFar );
|
||||
|
||||
// Depends on fYOffset.
|
||||
/**
|
||||
* @brief Retrieve the current brightness.
|
||||
*
|
||||
* Note that this depends on fYOffset.
|
||||
* @param pPlayerState the present PlayerState.
|
||||
* @param fNoteBeat the current beat.
|
||||
* @return the current brightness. */
|
||||
static float GetBrightness( const PlayerState* pPlayerState, float fNoteBeat );
|
||||
|
||||
// This is the zoom of the individual tracks, not of the whole Player.
|
||||
@@ -69,8 +88,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+22
-4
@@ -5,12 +5,18 @@
|
||||
#include "PlayerNumber.h"
|
||||
class Song;
|
||||
class PlayerState;
|
||||
|
||||
/** @brief An action made against a Player to make things more difficult. */
|
||||
struct Attack
|
||||
{
|
||||
AttackLevel level;
|
||||
float fStartSecond; // -1 = now
|
||||
/**
|
||||
* @brief the starting point of this attack.
|
||||
*
|
||||
* If this is -1, then the attack starts now. */
|
||||
float fStartSecond;
|
||||
/** @brief How long does this attack last? */
|
||||
float fSecsRemaining;
|
||||
/** @brief The modifiers used for this attack. */
|
||||
RString sModifiers;
|
||||
bool bOn; // set and used by GAMESTATE
|
||||
bool bGlobal; // true for song-wide course mods
|
||||
@@ -47,7 +53,14 @@ struct Attack
|
||||
|
||||
void GetAttackBeats( const Song *pSong, float &fStartBeat, float &fEndBeat ) const;
|
||||
void GetRealtimeAttackBeats( const Song *pSong, const PlayerState* pPlayerState, float &fStartBeat, float &fEndBeat ) const;
|
||||
/**
|
||||
* @brief Determine if this attack has no modifiers, and is thus blank or empty.
|
||||
* @return true if it is blank/empty, or false otherwise. */
|
||||
bool IsBlank() const { return sModifiers.empty(); }
|
||||
/**
|
||||
* @brief Determine if two Attacks are equal to each other.
|
||||
* @param rhs the other Attack in question.
|
||||
* @return true if the two Attacks are equal, or false otherwise. */
|
||||
bool operator== ( const Attack &rhs ) const;
|
||||
bool ContainsTransformOrTurn() const;
|
||||
static Attack FromGlobalCourseModifier( const RString &sModifiers );
|
||||
@@ -56,13 +69,18 @@ struct Attack
|
||||
|
||||
struct AttackArray : public vector<Attack>
|
||||
{
|
||||
/**
|
||||
* @brief Determine if the list of attacks contains a transform or turn mod.
|
||||
* @return true if it does, or false otherwise. */
|
||||
bool ContainsTransformOrTurn() const;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-4
@@ -1,4 +1,3 @@
|
||||
/* AttackDisplay - A graphical display for attacks. */
|
||||
#ifndef AttackDisplay_H
|
||||
#define AttackDisplay_H
|
||||
|
||||
@@ -8,7 +7,7 @@
|
||||
#include "RageTexturePreloader.h"
|
||||
|
||||
class PlayerState;
|
||||
|
||||
/** @brief A graphical display for attacks. */
|
||||
class AttackDisplay : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -29,8 +28,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+13
-6
@@ -1,13 +1,14 @@
|
||||
/* AutoActor - Smart pointer for Actor. */
|
||||
|
||||
#ifndef AutoActor_H
|
||||
#define AutoActor_H
|
||||
|
||||
class Actor;
|
||||
class XNode;
|
||||
|
||||
// creates the appropriate Actor derivitive on load and
|
||||
// automatically deletes Actor on deconstruction.
|
||||
/**
|
||||
* @brief A smart pointer for Actor.
|
||||
*
|
||||
* This creates the appropriate Actor derivative on load and
|
||||
* automatically deletes the Actor on deconstruction. */
|
||||
class AutoActor
|
||||
{
|
||||
public:
|
||||
@@ -20,6 +21,9 @@ public:
|
||||
const Actor *operator->() const { return m_pActor; }
|
||||
Actor *operator->() { return m_pActor; }
|
||||
void Unload();
|
||||
/**
|
||||
* @brief Determine if this actor is presently loaded.
|
||||
* @return true if it is loaded, or false otherwise. */
|
||||
bool IsLoaded() const { return m_pActor != NULL; }
|
||||
void Load( Actor *pActor ); // transfer pointer
|
||||
void Load( const RString &sPath );
|
||||
@@ -28,13 +32,16 @@ public:
|
||||
void LoadAndSetName( const RString &sScreenName, const RString &sActorName );
|
||||
|
||||
protected:
|
||||
/** @brief the Actor for which there is a smart pointer to. */
|
||||
Actor* m_pActor;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+6
-4
@@ -1,5 +1,3 @@
|
||||
/* AutoKeysounds - handle playback of auto keysound notes. */
|
||||
|
||||
#ifndef AUTO_KEYSOUNDS_H
|
||||
#define AUTO_KEYSOUNDS_H
|
||||
|
||||
@@ -10,11 +8,13 @@
|
||||
class RageSoundReader;
|
||||
class RageSoundReader_Chain;
|
||||
class Song;
|
||||
/** @brief Handle playback of auto keysound notes. */
|
||||
class AutoKeysounds
|
||||
{
|
||||
public:
|
||||
void Load( PlayerNumber pn, const NoteData& ndAutoKeysoundsOnly );
|
||||
void Update( float fDelta );
|
||||
/** @brief Finish loading the main sounds, and setup the auto keysounds if any. */
|
||||
void FinishLoading();
|
||||
RageSound *GetSound() { return &m_sSound; }
|
||||
RageSoundReader *GetSharedSound() { return m_pSharedSound; }
|
||||
@@ -34,8 +34,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2004 Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Glenn Maynard (c) 2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-4
@@ -1,5 +1,3 @@
|
||||
/* BGAnimation - An ActorFrame that loads itself. */
|
||||
|
||||
#ifndef BGANIMATION_H
|
||||
#define BGANIMATION_H
|
||||
|
||||
@@ -7,6 +5,7 @@
|
||||
|
||||
class XNode;
|
||||
|
||||
/** @brief An ActorFrame that loads itself. */
|
||||
class BGAnimation : public ActorFrameAutoDeleteChildren
|
||||
{
|
||||
public:
|
||||
@@ -24,8 +23,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Ben Nordstrom, Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Ben Nordstrom, Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/* BGAnimationLayer - layer elements used by BGAnimation */
|
||||
|
||||
#ifndef BGANIMATIONLAYER_H
|
||||
#define BGANIMATIONLAYER_H
|
||||
|
||||
@@ -9,6 +7,7 @@
|
||||
|
||||
class XNode;
|
||||
|
||||
/** @brief Layer elements used by BGAnimation. */
|
||||
class BGAnimationLayer : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -53,8 +52,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Ben Nordstrom, Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Ben Nordstrom, Chris Danford, Glenn Maynard (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -94,7 +94,6 @@ void BPMDisplay::Update( float fDeltaTime )
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void BPMDisplay::SetBPMRange( const DisplayBpms &bpms )
|
||||
{
|
||||
ASSERT( !bpms.vfBpms.empty() );
|
||||
|
||||
+1
-3
@@ -1,5 +1,3 @@
|
||||
/** @brief BPMDisplay - displays a BPM or a range of BPMs. */
|
||||
|
||||
#ifndef BPM_DISPLAY_H
|
||||
#define BPM_DISPLAY_H
|
||||
|
||||
@@ -11,7 +9,7 @@ class Song;
|
||||
class Course;
|
||||
struct DisplayBpms;
|
||||
|
||||
/** @brief Display the BPM/range of them as requested. */
|
||||
/** @brief Displays a BPM or a range of BPMs. */
|
||||
class BPMDisplay : public BitmapText
|
||||
{
|
||||
public:
|
||||
|
||||
+8
-5
@@ -1,5 +1,3 @@
|
||||
/* Background - Background behind notes while playing. */
|
||||
|
||||
#ifndef BACKGROUND_H
|
||||
#define BACKGROUND_H
|
||||
|
||||
@@ -11,7 +9,7 @@
|
||||
class DancingCharacters;
|
||||
class Song;
|
||||
class BackgroundImpl;
|
||||
|
||||
/** @brief the Background that is behind the notes while playing. */
|
||||
class Background : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -25,6 +23,9 @@ public:
|
||||
void FadeToActualBrightness();
|
||||
void SetBrightness( float fBrightness ); // overrides pref and Cover
|
||||
|
||||
/**
|
||||
* @brief Retrieve whatever dancing characters are in use.
|
||||
* @return the dancing characters. */
|
||||
DancingCharacters* GetDancingCharacters();
|
||||
|
||||
void GetLoadedBackgroundChanges( vector<BackgroundChange> **pBackgroundChangesOut );
|
||||
@@ -35,8 +36,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford, Ben Nordstrom
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Ben Nordstrom (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-5
@@ -1,5 +1,3 @@
|
||||
/* BannerCache - Maintains a cache of reduced-quality banners. */
|
||||
|
||||
#ifndef BANNER_CACHE_H
|
||||
#define BANNER_CACHE_H
|
||||
|
||||
@@ -8,7 +6,7 @@
|
||||
#include "RageTexture.h"
|
||||
|
||||
class LoadingWindow;
|
||||
|
||||
/** @brief Maintains a cache of reduced-quality banners. */
|
||||
class BannerCache
|
||||
{
|
||||
public:
|
||||
@@ -37,8 +35,10 @@ extern BannerCache *BANNERCACHE; // global and accessable from anywhere in our p
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Glenn Maynard (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
/* BeginnerHelper - A dancing character that follows the steps of the song. */
|
||||
#ifndef BEGINNER_HELPER_H
|
||||
#define BEGINNER_HELPER_H
|
||||
|
||||
@@ -8,7 +7,7 @@
|
||||
#include "PlayerNumber.h"
|
||||
#include "NoteData.h"
|
||||
class Model;
|
||||
|
||||
/** @brief A dancing character that follows the steps of the Song. */
|
||||
class BeginnerHelper : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -42,8 +41,10 @@ protected:
|
||||
};
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Kevin Slaughter, Thad Ward
|
||||
/**
|
||||
* @file
|
||||
* @author Kevin Slaughter, Thad Ward (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+8
-3
@@ -328,6 +328,9 @@ void BitmapText::DrawChars( bool bUseStrokeTexture )
|
||||
}
|
||||
}
|
||||
|
||||
vector<RageSpriteVertex*> vertices;
|
||||
int iNumVertsToDraw = 0;
|
||||
|
||||
for( int start = iStartGlyph; start < iEndGlyph; )
|
||||
{
|
||||
int end = start;
|
||||
@@ -348,14 +351,16 @@ void BitmapText::DrawChars( bool bUseStrokeTexture )
|
||||
* the texture wrapping state. If setting the wrapping state is found to be slow,
|
||||
* there should probably be a "don't care" texture wrapping mode set in Actor. -Chris */
|
||||
Actor::SetTextureRenderStates();
|
||||
|
||||
|
||||
RageSpriteVertex &start_vertex = m_aVertices[start*4];
|
||||
int iNumVertsToDraw = (end-start)*4;
|
||||
DISPLAY->DrawQuads( &start_vertex, iNumVertsToDraw );
|
||||
vertices.push_back(&start_vertex);
|
||||
iNumVertsToDraw += (end-start)*4;
|
||||
}
|
||||
|
||||
start = end;
|
||||
}
|
||||
if (!vertices.empty())
|
||||
DISPLAY->DrawQuads( vertices[0], iNumVertsToDraw );
|
||||
}
|
||||
|
||||
/* sText is UTF-8. If not all of the characters in sText are available in the
|
||||
|
||||
+5
-5
@@ -1,5 +1,3 @@
|
||||
/* BitmapText - An actor that holds a Font and draws text to the screen. */
|
||||
|
||||
#ifndef BITMAP_TEXT_H
|
||||
#define BITMAP_TEXT_H
|
||||
|
||||
@@ -9,7 +7,7 @@
|
||||
class RageTexture;
|
||||
class Font;
|
||||
struct FontPageTextures;
|
||||
|
||||
/** @brief An actor that holds a Font and draws text to the screen. */
|
||||
class BitmapText : public Actor
|
||||
{
|
||||
public:
|
||||
@@ -101,8 +99,10 @@ private:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2007 Chris Danford, Charles Lohr, Steve Checkoway
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Charles Lohr, Steve Checkoway (c) 2001-2007
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
#include "XmlFileUtil.h"
|
||||
#include <ctime>
|
||||
|
||||
|
||||
Bookkeeper* BOOKKEEPER = NULL; // global and accessable from anywhere in our program
|
||||
|
||||
static const RString COINS_DAT = "Save/Coins.xml";
|
||||
@@ -18,7 +17,6 @@ static const RString COINS_DAT = "Save/Coins.xml";
|
||||
Bookkeeper::Bookkeeper()
|
||||
{
|
||||
ClearAll();
|
||||
|
||||
ReadFromDisk();
|
||||
}
|
||||
|
||||
@@ -172,7 +170,6 @@ int Bookkeeper::GetCoinsTotal() const
|
||||
return GetNumCoinsInRange( m_mapCoinsForHour.begin(), m_mapCoinsForHour.end() );
|
||||
}
|
||||
|
||||
|
||||
void Bookkeeper::GetCoinsLastDays( int coins[NUM_LAST_DAYS] ) const
|
||||
{
|
||||
time_t lOldTime = time(NULL);
|
||||
|
||||
@@ -61,7 +61,6 @@ private:
|
||||
map<Date,int> m_mapCoinsForHour;
|
||||
};
|
||||
|
||||
|
||||
extern Bookkeeper* BOOKKEEPER; // global and accessable from anywhere in our program
|
||||
|
||||
#endif
|
||||
|
||||
+6
-5
@@ -1,5 +1,3 @@
|
||||
/* Character - An persona that defines attacks for use in battle. */
|
||||
|
||||
#ifndef Character_H
|
||||
#define Character_H
|
||||
|
||||
@@ -9,14 +7,14 @@
|
||||
struct lua_State;
|
||||
typedef lua_State Lua;
|
||||
|
||||
|
||||
/** @brief A persona that defines attacks for use in battle. */
|
||||
class Character
|
||||
{
|
||||
public:
|
||||
Character();
|
||||
~Character() { }
|
||||
|
||||
bool Load( RString sCharDir ); // return true if success
|
||||
bool Load( RString sCharDir ); // return true if successful
|
||||
|
||||
RString GetTakingABreakPath() const;
|
||||
RString GetCardPath() const { return m_sCardPath; }
|
||||
@@ -55,7 +53,10 @@ private:
|
||||
public:
|
||||
apActorCommands m_cmdInit;
|
||||
|
||||
// All the stuff below will be filled in if this character is playable in Rave mode
|
||||
/**
|
||||
* @brief Is this character playable in the Rave mode?
|
||||
*
|
||||
* All of the variables listed below here will be filled in if true. */
|
||||
bool m_bUsableInRave;
|
||||
|
||||
RString m_sAttacks[NUM_ATTACK_LEVELS][NUM_ATTACKS_PER_LEVEL];
|
||||
|
||||
+16
-7
@@ -5,7 +5,7 @@
|
||||
#include "GameConstantsAndTypes.h"
|
||||
#include "ActorFrame.h"
|
||||
|
||||
|
||||
/** @brief Multiple Players sharing one LifeMeter. */
|
||||
class CombinedLifeMeter : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -13,11 +13,18 @@ public:
|
||||
virtual ~CombinedLifeMeter() {};
|
||||
|
||||
virtual void OnLoadSong() {};
|
||||
/* Change life after receiving a tap note grade. This *is* called for
|
||||
* the head of hold notes. */
|
||||
/**
|
||||
* @brief Change life after receiving a tap note grade.
|
||||
*
|
||||
* Note that this *is* called for the head of hold/roll notes.
|
||||
* @param pn the PlayerNumber that hit the TapNote.
|
||||
* @param tns the score received from the TapNote. */
|
||||
virtual void ChangeLife( PlayerNumber pn, TapNoteScore tns ) = 0;
|
||||
/* Change life after receiving a hold note grade. tscore is the score
|
||||
* received for the initial tap note. */
|
||||
/**
|
||||
* @brief Change life after receiving a hold note grade.
|
||||
* @param pn the PlayerNumber that received the hold note score.
|
||||
* @param hns the hold note score recently received.
|
||||
* @param tns the score from the initial TapNote. */
|
||||
virtual void ChangeLife( PlayerNumber pn, HoldNoteScore hns, TapNoteScore tns ) = 0;
|
||||
virtual void HandleTapScoreNone( PlayerNumber pn ) = 0;
|
||||
};
|
||||
@@ -26,8 +33,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
/* CombinedLifeMeterTug - Dance Magic-like tug-o-war life meter. */
|
||||
|
||||
#ifndef CombinedLifeMeterTug_H
|
||||
#define CombinedLifeMeterTug_H
|
||||
|
||||
#include "CombinedLifeMeter.h"
|
||||
#include "MeterDisplay.h"
|
||||
|
||||
|
||||
/** @brief Dance Magic-like tug-o-war life meter. */
|
||||
class CombinedLifeMeterTug : public CombinedLifeMeter
|
||||
{
|
||||
public:
|
||||
@@ -27,8 +25,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+4
-3
@@ -1,5 +1,3 @@
|
||||
/** @brief CommonMetrics - Definitions of metrics that are in the "Common" group */
|
||||
|
||||
#ifndef COMMON_METRICS_H
|
||||
#define COMMON_METRICS_H
|
||||
|
||||
@@ -42,7 +40,10 @@ private:
|
||||
};
|
||||
|
||||
|
||||
/** @brief The common metrics that are used throughout. */
|
||||
/**
|
||||
* @brief Definitions of metrics that are in the "Common" group.
|
||||
*
|
||||
* These metrics are used throughout the metrics file. */
|
||||
namespace CommonMetrics
|
||||
{
|
||||
/** @brief The first screen in the attract loop. */
|
||||
|
||||
+103
-12
@@ -4,12 +4,30 @@
|
||||
#include "EnumHelper.h"
|
||||
#include <ctime>
|
||||
|
||||
/** @brief The number of days we check for previously. */
|
||||
const int NUM_LAST_DAYS = 7;
|
||||
/** @brief The number of weeks we check for previously. */
|
||||
const int NUM_LAST_WEEKS = 52;
|
||||
const int DAYS_IN_YEAR = 366; // maximum (leap years)
|
||||
/**
|
||||
* @brief The number of days that are in a year.
|
||||
*
|
||||
* This is set up to be a maximum for leap years. */
|
||||
const int DAYS_IN_YEAR = 366;
|
||||
/**
|
||||
* @brief The number of hours in a day. */
|
||||
const int HOURS_IN_DAY = 24;
|
||||
/**
|
||||
* @brief The number of days that are in a week. */
|
||||
const int DAYS_IN_WEEK = 7;
|
||||
enum Month { NUM_Month = 12, Month_Invalid };
|
||||
/** @brief Which month are we focusing on?
|
||||
*
|
||||
* Is there any reason why the actual months aren't defined
|
||||
* in here? -Wolfman2000 */
|
||||
enum Month
|
||||
{
|
||||
NUM_Month = 12, /**< The number of months in the year. */
|
||||
Month_Invalid /**< There should be no month at this point. */
|
||||
};
|
||||
|
||||
RString DayInYearToString( int iDayInYearIndex );
|
||||
RString LastDayToString( int iLastDayIndex );
|
||||
@@ -31,37 +49,110 @@ tm GetNextSunday( tm start );
|
||||
|
||||
tm GetDayInYearAndYear( int iDayInYearIndex, int iYear );
|
||||
|
||||
|
||||
/** @brief A standard way of determining the date and the time. */
|
||||
struct DateTime
|
||||
{
|
||||
int tm_sec; /* seconds after the minute - [0,59] */
|
||||
int tm_min; /* minutes after the hour - [0,59] */
|
||||
int tm_hour; /* hours since midnight - [0,23] */
|
||||
int tm_mday; /* day of the month - [1,31] */
|
||||
int tm_mon; /* months since January - [0,11] */
|
||||
int tm_year; /* years since 1900 */
|
||||
/**
|
||||
* @brief The number of seconds after the minute.
|
||||
*
|
||||
* Valid values are [0, 59]. */
|
||||
int tm_sec;
|
||||
/**
|
||||
* @brief The number of minutes after the hour.
|
||||
*
|
||||
* Valid values are [0, 59]. */
|
||||
int tm_min;
|
||||
/**
|
||||
* @brief The number of hours since midnight (or 0000 hours).
|
||||
*
|
||||
* Valid values are [0, 23]. */
|
||||
int tm_hour;
|
||||
/**
|
||||
* @brief The specified day of the current month.
|
||||
*
|
||||
* Valid values are [1, 31].
|
||||
*
|
||||
* XXX: Is it possible to set an illegal date through here,
|
||||
* such as day 30 of February? -Wolfman2000 */
|
||||
int tm_mday;
|
||||
/**
|
||||
* @brief The number of months since January.
|
||||
*
|
||||
* Valid values are [0, 11]. */
|
||||
int tm_mon;
|
||||
/** @brief The number of years since the year 1900. */
|
||||
int tm_year;
|
||||
|
||||
/** @brief Set up a default date and time. */
|
||||
DateTime();
|
||||
/** @brief Initialize the date and time. */
|
||||
void Init();
|
||||
|
||||
/**
|
||||
* @brief Determine if this DateTime is less than some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is less than the other time, or false otherwise. */
|
||||
bool operator<( const DateTime& other ) const;
|
||||
/**
|
||||
* @brief Determine if this DateTime is greater than some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is greater than the other time, or false otherwise. */
|
||||
bool operator>( const DateTime& other ) const;
|
||||
/**
|
||||
* @brief Determine if this DateTime is equal to some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is equal to the other time, or false otherwise. */
|
||||
bool operator==( const DateTime& other ) const;
|
||||
/**
|
||||
* @brief Determine if this DateTime is not equal to some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is not equal to the other time, or false otherwise. */
|
||||
bool operator!=( const DateTime& other ) const { return !operator==(other); }
|
||||
/**
|
||||
* @brief Determine if this DateTime is less than or equal to some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is less than or equal to the other time, or false otherwise. */
|
||||
bool operator<=( const DateTime& other ) const { return !operator>(other); }
|
||||
|
||||
/**
|
||||
* @brief Determine if this DateTime is greater than or equal to some other time.
|
||||
* @param other the other DateTime to check.
|
||||
* @return true if this is greater than or equal to the other time, or false otherwise. */
|
||||
bool operator>=( const DateTime& other ) const { return !operator<(other); }
|
||||
|
||||
/**
|
||||
* @brief Retrieve the current date and time.
|
||||
* @return the current date and time. */
|
||||
static DateTime GetNowDateTime();
|
||||
static DateTime GetNowDate(); // GetNowDateTime() with time chopped off
|
||||
/**
|
||||
* @brief Retrieve the current date.
|
||||
* @return the current date. */
|
||||
static DateTime GetNowDate();
|
||||
|
||||
/** @brief Remove the time portion from the date. */
|
||||
void StripTime();
|
||||
|
||||
/**
|
||||
* @brief Retrieve a string representation of the current date and time.
|
||||
*
|
||||
* This returns a common SQL/XML format: "YYYY-MM-DD HH:MM:SS".
|
||||
* @return the string representation of the date and time. */
|
||||
RString GetString() const;
|
||||
/**
|
||||
* @brief Attempt to turn a string into a DateTime.
|
||||
*
|
||||
* As a warning for the squeamish, this code uses the goto keyword.
|
||||
* @param sDateTime the string to attempt to convert.
|
||||
* @return true if the conversion worked, or false otherwise. */
|
||||
bool FromString( const RString sDateTime );
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -2,16 +2,24 @@
|
||||
#define DisplayResolutions_H
|
||||
|
||||
#include <set>
|
||||
|
||||
/** @brief The dimensions of the program. */
|
||||
class DisplayResolution
|
||||
{
|
||||
public:
|
||||
/** @brief The width of the program. */
|
||||
int iWidth;
|
||||
/** @brief The height of the program. */
|
||||
int iHeight;
|
||||
/** @brief Is this display stretched/used for widescreen? */
|
||||
bool bStretched;
|
||||
|
||||
/**
|
||||
* @brief Determine if one DisplayResolution is less than the other.
|
||||
* @param other the other DisplayResolution to check.
|
||||
* @return true if this DisplayResolution is less than the other, or false otherwise. */
|
||||
bool operator<( const DisplayResolution &other ) const
|
||||
{
|
||||
/** @brief A quick way to compare the two DisplayResolutions. */
|
||||
#define COMPARE(x) if( x != other.x ) return x < other.x;
|
||||
COMPARE( iWidth );
|
||||
COMPARE( iHeight );
|
||||
@@ -20,13 +28,15 @@ public:
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
/** @brief The collection of DisplayResolutions available within the program. */
|
||||
typedef set<DisplayResolution> DisplayResolutions;
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2005 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2005
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
/* DynamicActorScroller - ActorScroller that fills in its children on the fly. */
|
||||
|
||||
#ifndef ACTOR_SCROLLER_H
|
||||
#define ACTOR_SCROLLER_H
|
||||
|
||||
#include "ActorScroller.h"
|
||||
#include "LuaReference.h"
|
||||
|
||||
/** @brief ActorScroller that fills in its children on the fly. */
|
||||
class DynamicActorScroller: public ActorScroller
|
||||
{
|
||||
public:
|
||||
@@ -18,7 +16,7 @@ protected:
|
||||
|
||||
LuaReference m_LoadFunction;
|
||||
};
|
||||
|
||||
/** @brief an ActorScroller that deletes its children automatically. */
|
||||
class DynamicActorScrollerAutoDeleteChildren: public DynamicActorScroller
|
||||
{
|
||||
public:
|
||||
@@ -29,8 +27,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2005 Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Glenn Maynard (c) 2005
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -40,8 +40,6 @@ void FontManager::ReloadFonts()
|
||||
|
||||
Font* FontManager::LoadFont( const RString &sFontOrTextureFilePath, RString sChars )
|
||||
{
|
||||
PruneFonts();
|
||||
|
||||
Font *pFont;
|
||||
/* Convert the path to lowercase so that we don't load duplicates. Really,
|
||||
* this does not solve the duplicate problem. We could have two copies of
|
||||
|
||||
@@ -36,6 +36,7 @@ static const char *RadarCategoryNames[] = {
|
||||
"Hands",
|
||||
"Rolls",
|
||||
"Lifts",
|
||||
"Fakes",
|
||||
};
|
||||
XToString( RadarCategory );
|
||||
XToLocalizedString( RadarCategory );
|
||||
|
||||
@@ -39,6 +39,7 @@ enum RadarCategory
|
||||
RadarCategory_Hands, /**< How many hands are in the song? */
|
||||
RadarCategory_Rolls, /**< How many rolls are in the song? */
|
||||
RadarCategory_Lifts, /**< How many lifts are in the song? */
|
||||
RadarCategory_Fakes, /**< How many fakes are in the song? */
|
||||
NUM_RadarCategory, /**< The number of radar categories. */
|
||||
RadarCategory_Invalid
|
||||
};
|
||||
@@ -583,7 +584,8 @@ enum SampleMusicPreviewMode
|
||||
{
|
||||
SampleMusicPreviewMode_Normal, /**< Music is played as the song is highlighted. */
|
||||
SampleMusicPreviewMode_StartToPreview,
|
||||
SampleMusicPreviewMode_ScreenMusic, /**< No music plays. Select it once to preview the music, then once more to select the song. */
|
||||
SampleMusicPreviewMode_ScreenMusic, /**< No music plays. Select it once to preview the music,
|
||||
* then once more to select the song. */
|
||||
SampleMusicPreviewMode_LastSong, /**< continue playing the last song */
|
||||
NUM_SampleMusicPreviewMode,
|
||||
SampleMusicPreviewMode_Invalid,
|
||||
@@ -605,7 +607,8 @@ enum Stage
|
||||
Stage_4th, /**< The fourth stage. */
|
||||
Stage_5th, /**< The fifth stage. */
|
||||
Stage_6th, /**< The sixth stage. */
|
||||
Stage_Next, /**< Somewhere between the sixth and final stage. This won't normally happen because 7 stages is the max in the UI. */
|
||||
Stage_Next, /**< Somewhere between the sixth and final stage.
|
||||
* This won't normally happen because 7 stages is the max in the UI. */
|
||||
Stage_Final, /**< The last stage. */
|
||||
Stage_Extra1, /**< The first bonus stage, AKA the extra stage. */
|
||||
Stage_Extra2, /**< The last bonus stage, AKA the encore extra stage. */
|
||||
|
||||
+27
-14
@@ -1,5 +1,3 @@
|
||||
/* GameInput - An input event specific to an InputScheme defined by a logical controller and button. */
|
||||
|
||||
#ifndef GAME_INPUT_H
|
||||
#define GAME_INPUT_H
|
||||
|
||||
@@ -7,27 +5,29 @@
|
||||
|
||||
class InputScheme;
|
||||
|
||||
/** @brief the list of controllers in use. */
|
||||
enum GameController
|
||||
{
|
||||
GameController_1 = 0, // left controller
|
||||
GameController_2, // right controller
|
||||
NUM_GameController, // leave this at the end
|
||||
GameController_1 = 0, /**< The left controller */
|
||||
GameController_2, /**< The right controller */
|
||||
NUM_GameController, /**< The number of controllers allowed. */
|
||||
GameController_Invalid,
|
||||
};
|
||||
const RString& GameControllerToString( GameController mp );
|
||||
LuaDeclareType( GameController );
|
||||
|
||||
/** @brief the list of buttons StepMania recognizes. */
|
||||
enum GameButton
|
||||
{
|
||||
GAME_BUTTON_MENULEFT,
|
||||
GAME_BUTTON_MENURIGHT,
|
||||
GAME_BUTTON_MENUUP,
|
||||
GAME_BUTTON_MENUDOWN,
|
||||
GAME_BUTTON_MENULEFT, /**< Navigate the menus to the left. */
|
||||
GAME_BUTTON_MENURIGHT, /**< Navigate the menus to the right. */
|
||||
GAME_BUTTON_MENUUP, /**< Navigate the menus to the top. */
|
||||
GAME_BUTTON_MENUDOWN, /**< Navigate the menus to the bottom. */
|
||||
GAME_BUTTON_START,
|
||||
GAME_BUTTON_SELECT,
|
||||
GAME_BUTTON_BACK,
|
||||
GAME_BUTTON_COIN,
|
||||
GAME_BUTTON_OPERATOR,
|
||||
GAME_BUTTON_COIN, /**< Insert a coin to play. */
|
||||
GAME_BUTTON_OPERATOR, /**< Access the operator menu. */
|
||||
GAME_BUTTON_EFFECT_UP,
|
||||
GAME_BUTTON_EFFECT_DOWN,
|
||||
GAME_BUTTON_CUSTOM_01,
|
||||
@@ -64,18 +64,29 @@ GameButton StringToGameButton( const InputScheme* pInputs, const RString& s );
|
||||
#define GAME_BUTTON_NEXT GAME_BUTTON_CUSTOM_01
|
||||
|
||||
// dance
|
||||
/** @brief Set up the left arrow for dance mode. */
|
||||
#define DANCE_BUTTON_LEFT GAME_BUTTON_CUSTOM_01
|
||||
/** @brief Set up the right arrow for dance mode. */
|
||||
#define DANCE_BUTTON_RIGHT GAME_BUTTON_CUSTOM_02
|
||||
/** @brief Set up the up arrow for dance mode. */
|
||||
#define DANCE_BUTTON_UP GAME_BUTTON_CUSTOM_03
|
||||
/** @brief Set up the down arrow for dance mode. */
|
||||
#define DANCE_BUTTON_DOWN GAME_BUTTON_CUSTOM_04
|
||||
/** @brief Set up the upleft arrow for dance mode (solo). */
|
||||
#define DANCE_BUTTON_UPLEFT GAME_BUTTON_CUSTOM_05
|
||||
/** @brief Set up the upright arrow for dance mode (solo). */
|
||||
#define DANCE_BUTTON_UPRIGHT GAME_BUTTON_CUSTOM_06
|
||||
#define NUM_DANCE_BUTTONS GAME_BUTTON_CUSTOM_07
|
||||
// pump
|
||||
/** @brief Set up the upleft arrow for pump mode. */
|
||||
#define PUMP_BUTTON_UPLEFT GAME_BUTTON_CUSTOM_01
|
||||
/** @brief Set up the upright arrow for pump mode. */
|
||||
#define PUMP_BUTTON_UPRIGHT GAME_BUTTON_CUSTOM_02
|
||||
/** @brief Set up the center arrow for pump mode. */
|
||||
#define PUMP_BUTTON_CENTER GAME_BUTTON_CUSTOM_03
|
||||
/** @brief Set up the downleft arrow for pump mode. */
|
||||
#define PUMP_BUTTON_DOWNLEFT GAME_BUTTON_CUSTOM_04
|
||||
/** @brief Set up the downright arrow for pump mode. */
|
||||
#define PUMP_BUTTON_DOWNRIGHT GAME_BUTTON_CUSTOM_05
|
||||
#define NUM_PUMP_BUTTONS GAME_BUTTON_CUSTOM_06
|
||||
// kb7
|
||||
@@ -178,7 +189,7 @@ GameButton StringToGameButton( const InputScheme* pInputs, const RString& s );
|
||||
#define GAME_BUTTON_DOWN GAME_BUTTON_MENUDOWN
|
||||
#define GAME_BUTTON_START GAME_BUTTON_START
|
||||
#define GAME_BUTTON_BACK GAME_BUTTON_BACK
|
||||
|
||||
/** @brief An input event specific to an InputScheme defined by a logical controller and button. */
|
||||
struct GameInput
|
||||
{
|
||||
GameInput(): controller(GameController_Invalid), button(GameButton_Invalid) { }
|
||||
@@ -207,8 +218,10 @@ struct GameInput
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+9
-5
@@ -42,7 +42,6 @@
|
||||
#include <ctime>
|
||||
#include <set>
|
||||
|
||||
|
||||
GameState* GAMESTATE = NULL; // global and accessable from anywhere in our program
|
||||
|
||||
#define NAME_BLACKLIST_FILE "/Data/NamesBlacklist.txt"
|
||||
@@ -161,7 +160,7 @@ GameState::GameState() :
|
||||
m_Environment = new LuaTable;
|
||||
|
||||
// Don't reset yet; let the first screen do it, so we can use PREFSMAN and THEME.
|
||||
// Reset();
|
||||
//Reset();
|
||||
|
||||
// Register with Lua.
|
||||
{
|
||||
@@ -254,7 +253,7 @@ void GameState::Reset()
|
||||
m_MultiPlayerStatus[p] = MultiPlayerStatus_NotJoined;
|
||||
FOREACH_PlayerNumber( pn )
|
||||
MEMCARDMAN->UnlockCard( pn );
|
||||
// m_iCoins = 0; // don't reset coin count!
|
||||
//m_iCoins = 0; // don't reset coin count!
|
||||
m_bMultiplayer = false;
|
||||
m_iNumMultiplayerNoteFields = 1;
|
||||
*m_Environment = LuaTable();
|
||||
@@ -399,7 +398,7 @@ void GameState::UnjoinPlayer( PlayerNumber pn )
|
||||
}
|
||||
}
|
||||
|
||||
/* handle multiplayer join? */
|
||||
/* xxx: handle multiplayer join? -aj */
|
||||
|
||||
namespace
|
||||
{
|
||||
@@ -426,7 +425,7 @@ namespace
|
||||
}
|
||||
};
|
||||
|
||||
// Handle an input that can join a player. Return true if the player joined
|
||||
// Handle an input that can join a player. Return true if the player joined.
|
||||
bool GameState::JoinInput( PlayerNumber pn )
|
||||
{
|
||||
// When AutoJoin is enabled, join all players on a single start press.
|
||||
@@ -1461,6 +1460,11 @@ void GameState::LoadNoteSkinMetrics( PlayerNumber pn )
|
||||
RString m_sNoteSkin = m_pPlayerState[pn]->m_PlayerOptions.GetStage().m_sNoteSkin;
|
||||
RString sStepsType = StringConversion::ToString( this->m_pCurSteps[pn]->m_StepsType );
|
||||
LOG->Trace("Loading Row/Col/Size values for Noteskin %s | StepsType: %s",m_sNoteSkin.c_str(),sStepsType.c_str());
|
||||
|
||||
//m_iNoteSkinRowSpacing[pn] = NOTESKIN->GetMetricI( m_sNoteSkin, sStepsType, "RowSpacing" );
|
||||
// todo: allow per-column spacing values? -aj
|
||||
m_iNoteSkinColSpacing[pn] = NOTESKIN->GetMetricI( m_sNoteSkin, sStepsType, "ColSpacing" );
|
||||
m_iNoteSkinArrowSize[pn] = NOTESKIN->GetMetricI( m_sNoteSkin, sStepsType, "ArrowSize" );
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
+24
-24
@@ -78,9 +78,9 @@ public:
|
||||
* the three credits needed to begin the game. */
|
||||
BroadcastOnChange<int> m_iCoins;
|
||||
/** @brief The player number used with Styles where one player controls both sides. */
|
||||
PlayerNumber m_MasterPlayerNumber;
|
||||
bool m_bMultiplayer;
|
||||
int m_iNumMultiplayerNoteFields;
|
||||
PlayerNumber m_MasterPlayerNumber;
|
||||
bool m_bMultiplayer;
|
||||
int m_iNumMultiplayerNoteFields;
|
||||
bool DifficultiesLocked() const;
|
||||
bool ChangePreferredDifficultyAndStepsType( PlayerNumber pn, Difficulty dc, StepsType st );
|
||||
bool ChangePreferredDifficulty( PlayerNumber pn, int dir );
|
||||
@@ -90,24 +90,24 @@ public:
|
||||
Difficulty GetClosestShownDifficulty( PlayerNumber pn ) const;
|
||||
Difficulty GetEasiestStepsDifficulty() const;
|
||||
Difficulty GetHardestStepsDifficulty() const;
|
||||
RageTimer m_timeGameStarted; // from the moment the first player pressed Start
|
||||
LuaTable *m_Environment;
|
||||
RageTimer m_timeGameStarted; // from the moment the first player pressed Start
|
||||
LuaTable *m_Environment;
|
||||
|
||||
// This is set to a random number per-game/round; it can be used for a random seed.
|
||||
int m_iGameSeed, m_iStageSeed;
|
||||
RString m_sStageGUID;
|
||||
int m_iGameSeed, m_iStageSeed;
|
||||
RString m_sStageGUID;
|
||||
|
||||
/**
|
||||
* @brief Determine if a second player can join in at this time.
|
||||
* @return true if a player can still enter the game, false otherwise. */
|
||||
bool PlayersCanJoin() const;
|
||||
int GetCoinsNeededToJoin() const;
|
||||
bool EnoughCreditsToJoin() const { return m_iCoins >= GetCoinsNeededToJoin(); }
|
||||
bool PlayersCanJoin() const;
|
||||
int GetCoinsNeededToJoin() const;
|
||||
bool EnoughCreditsToJoin() const { return m_iCoins >= GetCoinsNeededToJoin(); }
|
||||
int GetNumSidesJoined() const;
|
||||
|
||||
const Game* GetCurrentGame();
|
||||
const Style* GetCurrentStyle() const;
|
||||
void SetCurrentStyle( const Style *pStyle );
|
||||
void SetCurrentStyle( const Style *pStyle );
|
||||
|
||||
void GetPlayerInfo( PlayerNumber pn, bool& bIsEnabledOut, bool& bIsHumanOut );
|
||||
bool IsPlayerEnabled( PlayerNumber pn ) const;
|
||||
@@ -115,6 +115,10 @@ public:
|
||||
bool IsPlayerEnabled( const PlayerState* pPlayerState ) const;
|
||||
int GetNumPlayersEnabled() const;
|
||||
|
||||
/**
|
||||
* @brief Is the specified Player a human Player?
|
||||
* @param pn the numbered Player to check.
|
||||
* @return true if it's a human Player, or false otherwise. */
|
||||
bool IsHumanPlayer( PlayerNumber pn ) const;
|
||||
int GetNumHumanPlayers() const;
|
||||
PlayerNumber GetFirstHumanPlayer() const;
|
||||
@@ -129,17 +133,17 @@ public:
|
||||
|
||||
BroadcastOnChange<RString> m_sPreferredSongGroup; // GROUP_ALL denotes no preferred group
|
||||
BroadcastOnChange<RString> m_sPreferredCourseGroup; // GROUP_ALL denotes no preferred group
|
||||
bool m_bChangedFailTypeOnScreenSongOptions; // true if FailType was changed in the song options screen
|
||||
bool m_bChangedFailTypeOnScreenSongOptions; // true if FailType was changed in the song options screen
|
||||
BroadcastOnChange<StepsType> m_PreferredStepsType;
|
||||
BroadcastOnChange1D<Difficulty,NUM_PLAYERS> m_PreferredDifficulty;
|
||||
BroadcastOnChange1D<CourseDifficulty,NUM_PLAYERS> m_PreferredCourseDifficulty;// used in nonstop
|
||||
BroadcastOnChange<SortOrder> m_SortOrder; // set by MusicWheel
|
||||
SortOrder m_PreferredSortOrder; // used by MusicWheel
|
||||
EditMode m_EditMode;
|
||||
bool IsEditing() const { return m_EditMode != EditMode_Invalid; }
|
||||
bool m_bDemonstrationOrJukebox; // ScreenGameplay does special stuff when this is true
|
||||
bool m_bJukeboxUsesModifiers;
|
||||
int m_iNumStagesOfThisSong;
|
||||
SortOrder m_PreferredSortOrder; // used by MusicWheel
|
||||
EditMode m_EditMode;
|
||||
bool IsEditing() const { return m_EditMode != EditMode_Invalid; }
|
||||
bool m_bDemonstrationOrJukebox; // ScreenGameplay does special stuff when this is true
|
||||
bool m_bJukeboxUsesModifiers;
|
||||
int m_iNumStagesOfThisSong;
|
||||
/**
|
||||
* @brief Increase this every stage while not resetting on a continue.
|
||||
*
|
||||
@@ -159,8 +163,8 @@ public:
|
||||
void CancelStage();
|
||||
void CommitStageStats();
|
||||
void FinishStage();
|
||||
int GetNumStagesLeft( PlayerNumber pn ) const;
|
||||
int GetSmallestNumStagesLeftForAnyHumanPlayer() const;
|
||||
int GetNumStagesLeft( PlayerNumber pn ) const;
|
||||
int GetSmallestNumStagesLeftForAnyHumanPlayer() const;
|
||||
bool IsFinalStageForAnyHumanPlayer() const;
|
||||
bool IsAnExtraStage() const;
|
||||
bool IsAnExtraStageAndSelectionLocked() const;
|
||||
@@ -173,7 +177,6 @@ public:
|
||||
bool m_bLoadingNextSong;
|
||||
int GetLoadingCourseSongIndex() const;
|
||||
|
||||
|
||||
// State Info used during gameplay
|
||||
|
||||
// NULL on ScreenSelectMusic if the currently selected wheel item isn't a Song.
|
||||
@@ -220,9 +223,6 @@ public:
|
||||
// not sure I want to let noteskins change row spacing, as that changes how
|
||||
// the speed mods work... -aj
|
||||
//int m_iNoteSkinRowSpacing[NUM_PLAYERS];
|
||||
// what are these for, exactly? -aj
|
||||
//bool m_bNoteSkinOverrideDim[NUM_PLAYERS];
|
||||
//bool m_bNoteSkinOverrideBright[NUM_PLAYERS];
|
||||
|
||||
float m_fMusicSecondsVisible;
|
||||
float m_fSongBeatVisible;
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/** @brief GameplayAssist - Encapsulate playing of handclap and metronome. */
|
||||
|
||||
#ifndef GameplayAssist_H
|
||||
#define GameplayAssist_H
|
||||
|
||||
|
||||
+5
-5
@@ -1,5 +1,3 @@
|
||||
/* GhostArrowRow - Row of GhostArrow actors. */
|
||||
|
||||
#ifndef GHOSTARROWROW_H
|
||||
#define GHOSTARROWROW_H
|
||||
|
||||
@@ -8,7 +6,7 @@
|
||||
#include "NoteTypes.h"
|
||||
|
||||
class PlayerState;
|
||||
|
||||
/** @brief Row of GhostArrow Actors. */
|
||||
class GhostArrowRow : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -34,8 +32,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -63,6 +63,7 @@ static inline RString GradeToString( Grade g )
|
||||
*
|
||||
* This is mainly for backward compatibility purposes, but the announcer
|
||||
* also uses it. Think "AAA", "B", etc.
|
||||
* This is only referenced in ScreenEvaluation at the moment.
|
||||
* @param g the current Grade.
|
||||
* @return the old styled grade string. */
|
||||
RString GradeToOldString( Grade g );
|
||||
|
||||
+12
-3
@@ -16,9 +16,16 @@ public:
|
||||
virtual GrooveRadar *Copy() const;
|
||||
virtual void LoadFromNode( const XNode* pNode );
|
||||
|
||||
/**
|
||||
* @brief Give the Player an empty GrooveRadar.
|
||||
* @param pn the Player to give an empty GrooveRadar. */
|
||||
void SetEmpty( PlayerNumber pn );
|
||||
void SetFromRadarValues( PlayerNumber pn, const RadarValues &rv );
|
||||
void SetFromSteps( PlayerNumber pn, Steps* pSteps ); // NULL means no Steps
|
||||
/**
|
||||
* @brief Give the Player a GrooveRadar based on some Steps.
|
||||
* @param pn the Player to give a GrooveRadar.
|
||||
* @param pSteps the Steps to use to make the radar. If NULL, there are no Steps. */
|
||||
void SetFromSteps( PlayerNumber pn, Steps* pSteps );
|
||||
|
||||
// Lua
|
||||
void PushSelf( lua_State *L );
|
||||
@@ -58,8 +65,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -58,6 +58,9 @@ struct HighScore
|
||||
* @return true if the score would be disqualified, false otherwise. */
|
||||
bool GetDisqualified() const;
|
||||
|
||||
/**
|
||||
* @brief Set the name of the Player that earned the score.
|
||||
* @param sName the name of the Player. */
|
||||
void SetName( const RString &sName );
|
||||
void SetGrade( Grade g );
|
||||
void SetScore( int iScore );
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
/* InputEventPlus - Holds a device input plus Game/Menu translations. */
|
||||
|
||||
#ifndef INPUT_EVENT_PLUS_H
|
||||
#define INPUT_EVENT_PLUS_H
|
||||
|
||||
#include "InputFilter.h"
|
||||
#include "GameInput.h"
|
||||
#include "PlayerNumber.h"
|
||||
|
||||
/** @brief Holds a device input plus Game/Menu translations. */
|
||||
class InputEventPlus
|
||||
{
|
||||
public:
|
||||
@@ -32,8 +30,10 @@ struct AlternateMapping
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+6
-5
@@ -1,5 +1,3 @@
|
||||
/* Inventory - Inventory management for PLAY_MODE_BATTLE. */
|
||||
|
||||
#ifndef Inventory_H
|
||||
#define Inventory_H
|
||||
|
||||
@@ -13,7 +11,7 @@ AutoScreenMessage( SM_BattleDamageLevel2 );
|
||||
AutoScreenMessage( SM_BattleDamageLevel3 );
|
||||
|
||||
class PlayerState;
|
||||
|
||||
/** @brief Inventory management for PLAY_MODE_BATTLE. */
|
||||
class Inventory : public Actor
|
||||
{
|
||||
public:
|
||||
@@ -32,6 +30,7 @@ protected:
|
||||
PlayerState* m_pPlayerState;
|
||||
int m_iLastSeenCombo;
|
||||
|
||||
/** @brief a sound played when an item has been acquired. */
|
||||
RageSound m_soundAcquireItem;
|
||||
vector<RageSound*> m_vpSoundUseItem;
|
||||
RageSound m_soundItemEnding;
|
||||
@@ -39,8 +38,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+15
-7
@@ -8,7 +8,7 @@
|
||||
|
||||
class PlayerState;
|
||||
class PlayerStageStats;
|
||||
|
||||
/** @brief The player's life. */
|
||||
class LifeMeter : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -22,11 +22,17 @@ public:
|
||||
}
|
||||
virtual void OnLoadSong() {};
|
||||
virtual void OnSongEnded() {};
|
||||
/* Change life after receiving a tap note grade. This *is* called for
|
||||
* the head of hold notes. */
|
||||
/**
|
||||
* @brief Change life after receiving a tap note grade.
|
||||
*
|
||||
* This *is* called for the head of hold notes.
|
||||
* @param score the tap note grade in question. */
|
||||
virtual void ChangeLife( TapNoteScore score ) = 0;
|
||||
/* Change life after receiving a hold note grade. tscore is the score
|
||||
* received for the initial tap note. */
|
||||
/**
|
||||
* @brief Change life after receiving a hold note grade.
|
||||
*
|
||||
* @param hns the hold note grade in question.
|
||||
* @param tns the score received for the initial tap note. */
|
||||
virtual void ChangeLife( HoldNoteScore hns, TapNoteScore tns ) = 0;
|
||||
virtual void HandleTapScoreNone() = 0;
|
||||
virtual bool IsInDanger() const = 0;
|
||||
@@ -50,8 +56,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2003 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-6
@@ -1,5 +1,3 @@
|
||||
/* LifeMeterBar - The player's life represented as a bar. */
|
||||
|
||||
#ifndef LIFEMETERBAR_H
|
||||
#define LIFEMETERBAR_H
|
||||
|
||||
@@ -10,7 +8,7 @@
|
||||
#include "ThemeMetric.h"
|
||||
class StreamDisplay;
|
||||
|
||||
|
||||
/** @brief The player's life represented as a bar. */
|
||||
class LifeMeterBar : public LifeMeter
|
||||
{
|
||||
public:
|
||||
@@ -59,9 +57,10 @@ private:
|
||||
float m_fLifeDifficulty; // essentially same as pref
|
||||
|
||||
int m_iProgressiveLifebar; // cached from prefs
|
||||
int m_iMissCombo; // current number of progressive W5/miss
|
||||
|
||||
int m_iComboToRegainLife; // combo needed before lifebar starts filling up after fail
|
||||
/** @brief The current number of progressive W5/miss rankings. */
|
||||
int m_iMissCombo;
|
||||
/** @brief The combo needed before the life bar starts to fill up after a Player failed. */
|
||||
int m_iComboToRegainLife;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -51,7 +51,9 @@ private:
|
||||
|
||||
PercentageDisplay m_Percent;
|
||||
|
||||
/** @brief The sound played when a Player loses a life. */
|
||||
RageSound m_soundLoseLife;
|
||||
/** @brief The sound played when a Player gains a life. */
|
||||
RageSound m_soundGainLife;
|
||||
};
|
||||
|
||||
|
||||
+6
-6
@@ -1,5 +1,3 @@
|
||||
/* LifeMeterTime - Battery life meter used in Survival. */
|
||||
|
||||
#ifndef LifeMeterTime_H
|
||||
#define LifeMeterTime_H
|
||||
|
||||
@@ -12,7 +10,7 @@
|
||||
#include "MeterDisplay.h"
|
||||
#include "Quad.h"
|
||||
class StreamDisplay;
|
||||
|
||||
/** @brief Battery life meter used in Survival. */
|
||||
class LifeMeterTime : public LifeMeter
|
||||
{
|
||||
public:
|
||||
@@ -42,15 +40,17 @@ private:
|
||||
|
||||
float m_fLifeTotalGainedSeconds;
|
||||
float m_fLifeTotalLostSeconds;
|
||||
|
||||
/** @brief The sound played when time is gained at the start of each Song. */
|
||||
RageSound m_soundGainLife;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/* LocalizedString - */
|
||||
|
||||
#ifndef LocalizedString_H
|
||||
#define LocalizedString_H
|
||||
|
||||
@@ -10,7 +8,7 @@ public:
|
||||
virtual void Load( const RString& sGroup, const RString& sName ) = 0;
|
||||
virtual const RString &GetLocalized() const = 0;
|
||||
};
|
||||
|
||||
/** @brief Get a String based on the user's natural language. */
|
||||
class LocalizedString
|
||||
{
|
||||
public:
|
||||
@@ -31,8 +29,10 @@ private:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Copyright (c) 2001-2005 Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Glenn Maynard (c) 2001-2005
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* LuaExpressionTransform - Handle transforming a list of items. Cache item transforms based on fPositionOffsetFromCenter and iItemIndex for speed. */
|
||||
/* LuaExpressionTransform - */
|
||||
|
||||
#ifndef LuaExpressionTransform_H
|
||||
#define LuaExpressionTransform_H
|
||||
@@ -7,6 +7,10 @@
|
||||
#include "LuaReference.h"
|
||||
#include <map>
|
||||
|
||||
/**
|
||||
* @brief Handle transforming a list of items
|
||||
*
|
||||
* Cache item transforms based on fPositionOffsetFromCenter and iItemIndex for speed. */
|
||||
class LuaExpressionTransform
|
||||
{
|
||||
public:
|
||||
|
||||
+9
-5
@@ -1,20 +1,24 @@
|
||||
/* LyricsLoader - Loads lyrics from an LRC file. */
|
||||
|
||||
#ifndef LYRICS_LOADER_H
|
||||
#define LYRICS_LOADER_H
|
||||
|
||||
class Song;
|
||||
|
||||
/** @brief Loads lyrics from an LRC file. */
|
||||
class LyricsLoader
|
||||
{
|
||||
public:
|
||||
/**
|
||||
* @brief Load the lyrics into the Song.
|
||||
* @param sPath the path to the Lyrics.
|
||||
* @param out the Song to receive the Lyrics. */
|
||||
bool LoadFromLRCFile( const RString& sPath, Song &out );
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003 Kevin Slaughter, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Kevin Slaughter, Glenn Maynard (c) 2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/* MessageManager - Control the world. */
|
||||
|
||||
#ifndef MessageManager_H
|
||||
#define MessageManager_H
|
||||
|
||||
@@ -8,6 +6,7 @@ struct lua_State;
|
||||
class LuaTable;
|
||||
class LuaReference;
|
||||
|
||||
/** @brief The various messages available to watch for. */
|
||||
enum MessageID
|
||||
{
|
||||
Message_CurrentGameChanged,
|
||||
@@ -173,7 +172,7 @@ private:
|
||||
vector<RString> m_vsSubscribedTo;
|
||||
};
|
||||
|
||||
|
||||
/** @brief Deliver messages to any part of the program as needed. */
|
||||
class MessageManager
|
||||
{
|
||||
public:
|
||||
|
||||
+13
-5
@@ -1,4 +1,3 @@
|
||||
/* ModelManager - Interface for loading and releasing textures. */
|
||||
#ifndef MODEL_MANAGER_H
|
||||
#define MODEL_MANAGER_H
|
||||
|
||||
@@ -25,7 +24,10 @@ struct ModelManagerPrefs
|
||||
m_bDelayedUnload != rhs.m_bDelayedUnload;
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Class for loading and releasing textures.
|
||||
*
|
||||
* Funnily enough, the original documentation claimed this was an Interface. */
|
||||
class ModelManager
|
||||
{
|
||||
public:
|
||||
@@ -36,7 +38,11 @@ public:
|
||||
void UnloadModel( RageModelGeometry *m );
|
||||
// void ReloadAll();
|
||||
|
||||
bool SetPrefs( const ModelManagerPrefs& prefs ); // returns true if needs display to be reset
|
||||
/**
|
||||
* @brief Set up new preferences.
|
||||
* @param prefs the new preferences to set up.
|
||||
* @return true if the display needs to be reset, false otherwise. */
|
||||
bool SetPrefs( const ModelManagerPrefs& prefs );
|
||||
const ModelManagerPrefs& GetPrefs() { return m_Prefs; }
|
||||
|
||||
protected:
|
||||
@@ -50,8 +56,10 @@ extern ModelManager* MODELMAN; // global and accessable from anywhere in our pro
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -635,6 +635,20 @@ int NoteData::GetNumLifts( int iStartIndex, int iEndIndex ) const
|
||||
return iNumLifts;
|
||||
}
|
||||
|
||||
int NoteData::GetNumFakes( int iStartIndex, int iEndIndex ) const
|
||||
{
|
||||
int iNumFakes = 0;
|
||||
|
||||
for( int t=0; t<GetNumTracks(); t++ )
|
||||
{
|
||||
FOREACH_NONEMPTY_ROW_IN_TRACK_RANGE( *this, t, r, iStartIndex, iEndIndex )
|
||||
if( GetTapNote(t, r).type == TapNote::fake )
|
||||
iNumFakes++;
|
||||
}
|
||||
|
||||
return iNumFakes;
|
||||
}
|
||||
|
||||
/*
|
||||
int NoteData::GetNumMinefields( int iStartIndex, int iEndIndex ) const
|
||||
{
|
||||
|
||||
@@ -233,6 +233,7 @@ public:
|
||||
|
||||
// and the other notetypes
|
||||
int GetNumLifts( int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW ) const;
|
||||
int GetNumFakes( int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW ) const;
|
||||
|
||||
// Transformations
|
||||
void LoadTransformed( const NoteData& original, int iNewNumTracks, const int iOriginalTrackToTakeFrom[] ); // -1 for iOriginalTracksToTakeFrom means no track
|
||||
|
||||
+72
-4
@@ -496,7 +496,7 @@ void NoteDataUtil::LoadTransformedSlidingWindow( const NoteData &in, NoteData &o
|
||||
{
|
||||
// reset all notes
|
||||
out.Init();
|
||||
|
||||
|
||||
if( in.GetNumTracks() > iNewNumTracks )
|
||||
{
|
||||
// Use a different algorithm for reducing tracks.
|
||||
@@ -561,6 +561,37 @@ void NoteDataUtil::LoadTransformedSlidingWindow( const NoteData &in, NoteData &o
|
||||
}
|
||||
}
|
||||
|
||||
void PlaceAutoKeysound( const NoteData &in, NoteData &out, int iNewNumTracks, int row, const TapNote &tnFrom )
|
||||
{
|
||||
int iEmptyTrack = -1;
|
||||
int iEmptyRow = row - 1;
|
||||
bool bFoundEmptyTrack = false;
|
||||
if( iEmptyRow < 0 )
|
||||
{
|
||||
iEmptyRow = 0;
|
||||
}
|
||||
for( int r = iEmptyRow; r <= iEmptyRow + 2; r += 2 )
|
||||
{
|
||||
for( int i = 0; i < iNewNumTracks; ++i )
|
||||
{
|
||||
if ( out.GetTapNote(i, r) == TAP_EMPTY )
|
||||
{
|
||||
iEmptyTrack = i;
|
||||
iEmptyRow = r;
|
||||
bFoundEmptyTrack = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if( bFoundEmptyTrack )
|
||||
break;
|
||||
}
|
||||
|
||||
if( iEmptyTrack != -1 )
|
||||
{
|
||||
out.SetTapNote( iEmptyTrack, iEmptyRow, tnFrom );
|
||||
}
|
||||
}
|
||||
|
||||
void NoteDataUtil::LoadOverlapped( const NoteData &in, NoteData &out, int iNewNumTracks )
|
||||
{
|
||||
out.SetNumTracks( iNewNumTracks );
|
||||
@@ -587,7 +618,7 @@ void NoteDataUtil::LoadOverlapped( const NoteData &in, NoteData &out, int iNewNu
|
||||
for( int iTrackFrom = 0; iTrackFrom < in.GetNumTracks(); ++iTrackFrom )
|
||||
{
|
||||
const TapNote &tnFrom = in.GetTapNote( iTrackFrom, row );
|
||||
if( tnFrom.type == TapNote::empty )
|
||||
if( tnFrom.type == TapNote::empty || tnFrom.type == TapNote::autoKeysound )
|
||||
continue;
|
||||
|
||||
// If this is a hold note, find the end.
|
||||
@@ -609,7 +640,16 @@ void NoteDataUtil::LoadOverlapped( const NoteData &in, NoteData &out, int iNewNu
|
||||
|
||||
// If it's still in use, then we just don't have an available track.
|
||||
if( iEndIndex - LastSourceRow[iTrackTo] < ShiftThreshold )
|
||||
{
|
||||
// If it has a keysound, put it in autokeysound track.
|
||||
if( tnFrom.iKeysoundIndex >= 0 )
|
||||
{
|
||||
TapNote akTap = tnFrom;
|
||||
akTap.type = TapNote::autoKeysound;
|
||||
PlaceAutoKeysound( in, out, iNewNumTracks, row, akTap );
|
||||
}
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
LastSourceTrack[iTrackTo] = iTrackFrom;
|
||||
@@ -621,6 +661,16 @@ void NoteDataUtil::LoadOverlapped( const NoteData &in, NoteData &out, int iNewNu
|
||||
out.SetTapNote( iTrackTo, iEndIndex, tnTail );
|
||||
}
|
||||
}
|
||||
|
||||
// find empty track for autokeysounds in 2 next rows, so you can hear most autokeysounds
|
||||
for( int iTrackFrom = 0; iTrackFrom < in.GetNumTracks(); ++iTrackFrom )
|
||||
{
|
||||
const TapNote &tnFrom = in.GetTapNote( iTrackFrom, row );
|
||||
if( tnFrom.type != TapNote::autoKeysound )
|
||||
continue;
|
||||
|
||||
PlaceAutoKeysound( in, out, iNewNumTracks, row, tnFrom );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -749,6 +799,7 @@ void NoteDataUtil::CalculateRadarValues( const NoteData &in, float fSongSeconds,
|
||||
case RadarCategory_Hands: out[rc] = (float) in.GetNumHands(); break;
|
||||
case RadarCategory_Rolls: out[rc] = (float) in.GetNumRolls(); break;
|
||||
case RadarCategory_Lifts: out[rc] = (float) in.GetNumLifts(); break;
|
||||
case RadarCategory_Fakes: out[rc] = (float) in.GetNumFakes(); break;
|
||||
default: ASSERT(0);
|
||||
}
|
||||
}
|
||||
@@ -928,14 +979,29 @@ void NoteDataUtil::RemoveQuads( NoteData &inout, int iStartIndex, int iEndIndex
|
||||
RemoveSimultaneousNotes( inout, 3, iStartIndex, iEndIndex );
|
||||
}
|
||||
|
||||
void NoteDataUtil::RemoveMines( NoteData &inout, int iStartIndex, int iEndIndex )
|
||||
void NoteDataUtil::RemoveSpecificTapNotes( NoteData &inout, TapNote::Type tn, int iStartIndex, int iEndIndex )
|
||||
{
|
||||
for( int t=0; t<inout.GetNumTracks(); t++ )
|
||||
FOREACH_NONEMPTY_ROW_IN_TRACK_RANGE( inout, t, r, iStartIndex, iEndIndex )
|
||||
if( inout.GetTapNote(t,r).type == TapNote::mine )
|
||||
if( inout.GetTapNote(t,r).type == tn )
|
||||
inout.SetTapNote( t, r, TAP_EMPTY );
|
||||
}
|
||||
|
||||
void NoteDataUtil::RemoveMines( NoteData &inout, int iStartIndex, int iEndIndex )
|
||||
{
|
||||
RemoveSpecificTapNotes( inout, TapNote::mine, iStartIndex, iEndIndex );
|
||||
}
|
||||
|
||||
void NoteDataUtil::RemoveLifts( NoteData &inout, int iStartIndex, int iEndIndex )
|
||||
{
|
||||
RemoveSpecificTapNotes( inout, TapNote::lift, iStartIndex, iEndIndex );
|
||||
}
|
||||
|
||||
void NoteDataUtil::RemoveFakes( NoteData &inout, int iStartIndex, int iEndIndex )
|
||||
{
|
||||
RemoveSpecificTapNotes( inout, TapNote::fake, iStartIndex, iEndIndex );
|
||||
}
|
||||
|
||||
void NoteDataUtil::RemoveAllButOneTap( NoteData &inout, int row )
|
||||
{
|
||||
if(row < 0) return;
|
||||
@@ -2093,6 +2159,8 @@ void NoteDataUtil::TransformNoteData( NoteData &nd, const PlayerOptions &po, Ste
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOHOLDS] ) NoteDataUtil::RemoveHoldNotes( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOMINES] ) NoteDataUtil::RemoveMines( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOJUMPS] ) NoteDataUtil::RemoveJumps( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOLIFTS] ) NoteDataUtil::RemoveLifts( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOFAKES] ) NoteDataUtil::RemoveFakes( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOHANDS] ) NoteDataUtil::RemoveHands( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOQUADS] ) NoteDataUtil::RemoveQuads( nd, iStartIndex, iEndIndex );
|
||||
if( po.m_bTransforms[PlayerOptions::TRANSFORM_NOSTRETCH] ) NoteDataUtil::RemoveStretch( nd, st, iStartIndex, iEndIndex );
|
||||
|
||||
+33
-2
@@ -39,6 +39,11 @@ namespace NoteDataUtil
|
||||
|
||||
void CalculateRadarValues( const NoteData &in, float fSongSeconds, RadarValues& out );
|
||||
|
||||
/**
|
||||
* @brief Remove all of the Hold notes.
|
||||
* @param inout the Notedata to be transformed.
|
||||
* @param iStartIndex the starting point for transforming.
|
||||
* @param iEndIndex the ending point for transforming. */
|
||||
void RemoveHoldNotes( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
void ChangeRollsToHolds( NoteData &in, int iStartIndex, int iEndIndex );
|
||||
void ChangeHoldsToRolls( NoteData &in, int iStartIndex, int iEndIndex );
|
||||
@@ -46,7 +51,31 @@ namespace NoteDataUtil
|
||||
void RemoveJumps( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
void RemoveHands( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
void RemoveQuads( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
/**
|
||||
* @brief Remove all of a specific TapNote Type.
|
||||
* @param inout the Notedata to be transformed.
|
||||
* @param tn the TapNote Type to remove.
|
||||
* @param iStartIndex the starting point for transforming.
|
||||
* @param iEndIndex the ending point for transforming. */
|
||||
void RemoveSpecificTapNotes( NoteData &inout, TapNote::Type tn, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
/**
|
||||
* @brief Remove all of the mines from the chart.
|
||||
* @param inout the Notedata to be transformed.
|
||||
* @param iStartIndex the starting point for transforming.
|
||||
* @param iEndIndex the ending point for transforming. */
|
||||
void RemoveMines( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
/**
|
||||
* @brief Remove all of the lifts from the chart.
|
||||
* @param inout the Notedata to be transformed.
|
||||
* @param iStartIndex the starting point for transforming.
|
||||
* @param iEndIndex the ending point for transforming. */
|
||||
void RemoveLifts( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
/**
|
||||
* @brief Remove all of the fakes from the chart.
|
||||
* @param inout the Notedata to be transformed.
|
||||
* @param iStartIndex the starting point for transforming.
|
||||
* @param iEndIndex the ending point for transforming. */
|
||||
void RemoveFakes( NoteData &inout, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
void RemoveStretch( NoteData &inout, StepsType st, int iStartIndex = 0, int iEndIndex = MAX_NOTE_ROW );
|
||||
void RemoveAllButOneTap( NoteData &inout, int row );
|
||||
void RemoveAllButPlayer( NoteData &inout, PlayerNumber pn );
|
||||
@@ -127,8 +156,10 @@ namespace NoteDataUtil
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Glenn Maynard (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -348,7 +348,8 @@ void NoteDataWithScoring::GetActualRadarValues( const NoteData &in, const Player
|
||||
case RadarCategory_Mines: out[rc] = (float) GetSuccessfulMines( in ); break;
|
||||
case RadarCategory_Hands: out[rc] = (float) GetSuccessfulHands( in ); break;
|
||||
case RadarCategory_Rolls: out[rc] = (float) GetNumHoldNotesWithScore( in, TapNote::hold_head_roll, HNS_Held ); break;
|
||||
case RadarCategory_Lifts: out[rc] = (float) GetSuccessfulLifts( in, TNS_W4 ); break;
|
||||
case RadarCategory_Lifts: out[rc] = (float) GetSuccessfulLifts( in, TNS_W4 ); break;
|
||||
case RadarCategory_Fakes: out[rc] = (float) in.GetNumLifts(); break;
|
||||
//case RadarCategory_Minefields: out[rc] = (float) GetNumMinefieldsWithScore( in, TapNote::hold_head_mine, HNS_Held ); break;
|
||||
DEFAULT_FAIL( rc );
|
||||
}
|
||||
|
||||
@@ -13,17 +13,25 @@ struct TapNote;
|
||||
/** @brief NoteData with scores for each TapNote and HoldNote. */
|
||||
namespace NoteDataWithScoring
|
||||
{
|
||||
/**
|
||||
* @brief Has the current row of NoteData been judged completely?
|
||||
* @param in the entire Notedata.
|
||||
* @param iRow the row to check.
|
||||
* @return true if it has been completley judged, or false otherwise. */
|
||||
bool IsRowCompletelyJudged( const NoteData &in, unsigned iRow );
|
||||
TapNoteScore MinTapNoteScore( const NoteData &in, unsigned iRow );
|
||||
const TapNote &LastTapNoteWithResult( const NoteData &in, unsigned iRow );
|
||||
|
||||
void GetActualRadarValues( const NoteData &in, const PlayerStageStats &pss, float fSongSeconds, RadarValues& out );
|
||||
void GetActualRadarValues( const NoteData &in, const PlayerStageStats &pss,
|
||||
float fSongSeconds, RadarValues& out );
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Glenn Maynard (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+17
-15
@@ -8,18 +8,18 @@ class PlayerState;
|
||||
struct TapNote;
|
||||
struct HoldNoteResult;
|
||||
struct NoteMetricCache_t;
|
||||
|
||||
/** @brief the various parts of a Note. */
|
||||
enum NotePart
|
||||
{
|
||||
NotePart_Tap,
|
||||
NotePart_Mine,
|
||||
NotePart_Lift,
|
||||
NotePart_Fake,
|
||||
NotePart_HoldHead,
|
||||
NotePart_HoldTail,
|
||||
NotePart_HoldTopCap,
|
||||
NotePart_HoldBody,
|
||||
NotePart_HoldBottomCap,
|
||||
NotePart_Tap, /**< The part representing a traditional TapNote. */
|
||||
NotePart_Mine, /**< The part representing a mine. */
|
||||
NotePart_Lift, /**< The part representing a lift note. */
|
||||
NotePart_Fake, /**< The part representing a fake note. */
|
||||
NotePart_HoldHead, /**< The part representing a hold head. */
|
||||
NotePart_HoldTail, /**< The part representing a hold tail. */
|
||||
NotePart_HoldTopCap, /**< The part representing a hold's top cap. */
|
||||
NotePart_HoldBody, /**< The part representing a hold's body. */
|
||||
NotePart_HoldBottomCap, /**< The part representing a hold's bottom cap. */
|
||||
NUM_NotePart,
|
||||
NotePart_Invalid
|
||||
};
|
||||
@@ -45,11 +45,11 @@ struct NoteColorSprite
|
||||
private:
|
||||
NoteResource *m_p;
|
||||
};
|
||||
|
||||
/** @brief What types of holds are there? */
|
||||
enum HoldType
|
||||
{
|
||||
hold,
|
||||
roll,
|
||||
hold, /**< Merely keep your foot held on the body for it to count. */
|
||||
roll, /**< Keep hitting the hold body for it to stay alive. */
|
||||
// minefield,
|
||||
NUM_HoldType,
|
||||
HoldType_Invalid
|
||||
@@ -120,8 +120,10 @@ private:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2006 Brian Bugh, Ben Nordstrom, Chris Danford, Steve Checkoway
|
||||
/**
|
||||
* @file
|
||||
* @author Brian Bugh, Ben Nordstrom, Chris Danford, Steve Checkoway (c) 2001-2006
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+5
-5
@@ -1,5 +1,3 @@
|
||||
/* NoteField - An Actor that renders a NoteData. */
|
||||
|
||||
#ifndef NOTE_FIELD_H
|
||||
#define NOTE_FIELD_H
|
||||
|
||||
@@ -13,7 +11,7 @@
|
||||
|
||||
struct Attack;
|
||||
class NoteData;
|
||||
|
||||
/** @brief An Actor that renders NoteData. */
|
||||
class NoteField : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -103,8 +101,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/* NoteSkinManager - Loads note skins. */
|
||||
|
||||
#ifndef NOTE_SKIN_MANAGER_H
|
||||
#define NOTE_SKIN_MANAGER_H
|
||||
|
||||
@@ -11,6 +9,7 @@
|
||||
class Game;
|
||||
struct NoteSkinData;
|
||||
|
||||
/** @brief Loads note skins. */
|
||||
class NoteSkinManager
|
||||
{
|
||||
public:
|
||||
@@ -49,8 +48,6 @@ protected:
|
||||
const Game* m_pCurGame;
|
||||
};
|
||||
|
||||
|
||||
|
||||
extern NoteSkinManager* NOTESKIN; // global and accessable from anywhere in our program
|
||||
|
||||
class LockNoteSkin
|
||||
@@ -63,8 +60,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2003-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -182,6 +182,7 @@ static StepsType DetermineStepsType( int iPlayer, const NoteData &nd, const RStr
|
||||
// are more common.
|
||||
//return StepsType_dance_solo;
|
||||
return StepsType_beat_single5;
|
||||
case 7:
|
||||
case 8: return StepsType_beat_single7;
|
||||
case 9: return StepsType_popn_nine;
|
||||
default: return StepsType_Invalid;
|
||||
|
||||
+10
-3
@@ -55,12 +55,19 @@ void SMLoader::LoadFromSMTokens(
|
||||
out.SetMeter( atoi(sMeter) );
|
||||
vector<RString> saValues;
|
||||
split( sRadarValues, ",", saValues, true );
|
||||
if( saValues.size() == NUM_RadarCategory * NUM_PLAYERS )
|
||||
int categories = NUM_RadarCategory - 1; // Fakes aren't counted in the radar values.
|
||||
if( saValues.size() == (unsigned)categories * NUM_PLAYERS )
|
||||
{
|
||||
RadarValues v[NUM_PLAYERS];
|
||||
FOREACH_PlayerNumber( pn )
|
||||
FOREACH_ENUM( RadarCategory, rc )
|
||||
v[pn][rc] = StringToFloat( saValues[pn*NUM_RadarCategory + rc] );
|
||||
{
|
||||
// Can't use the foreach anymore due to flexible radar lines.
|
||||
for( RadarCategory rc = (RadarCategory)0; rc < categories;
|
||||
enum_add<RadarCategory>( rc, 1 ) )
|
||||
{
|
||||
v[pn][rc] = StringToFloat( saValues[pn*categories + rc] );
|
||||
}
|
||||
}
|
||||
out.SetCachedRadarValues( v );
|
||||
}
|
||||
|
||||
|
||||
+15
-3
@@ -658,12 +658,23 @@ bool SSCLoader::LoadFromSSCFile( const RString &sPath, Song &out, bool bFromCach
|
||||
{
|
||||
vector<RString> saValues;
|
||||
split( sParams[1], ",", saValues, true );
|
||||
if( saValues.size() == NUM_RadarCategory * NUM_PLAYERS )
|
||||
|
||||
int categories = NUM_RadarCategory;
|
||||
if( out.m_fVersion < VERSION_RADAR_FAKE )
|
||||
categories -= 1;
|
||||
|
||||
if( saValues.size() == (unsigned)categories * NUM_PLAYERS )
|
||||
{
|
||||
RadarValues v[NUM_PLAYERS];
|
||||
FOREACH_PlayerNumber( pn )
|
||||
FOREACH_ENUM( RadarCategory, rc )
|
||||
v[pn][rc] = StringToFloat( saValues[pn*NUM_RadarCategory + rc] );
|
||||
{
|
||||
// Can't use the foreach anymore due to flexible radar lines.
|
||||
for( RadarCategory rc = (RadarCategory)0; rc < categories;
|
||||
enum_add<RadarCategory>( rc, +1 ) )
|
||||
{
|
||||
v[pn][rc] = StringToFloat( saValues[pn*categories + rc] );
|
||||
}
|
||||
}
|
||||
pNewNotes->SetCachedRadarValues( v );
|
||||
}
|
||||
}
|
||||
@@ -917,6 +928,7 @@ bool SSCLoader::LoadFromSSCFile( const RString &sPath, Song &out, bool bFromCach
|
||||
}
|
||||
}
|
||||
}
|
||||
out.m_fVersion = STEPFILE_VERSION_NUMBER;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -21,6 +21,8 @@ enum SSCLoadingStates
|
||||
NUM_SSCLoadingStates /**< The number of states used. */
|
||||
};
|
||||
|
||||
const float VERSION_RADAR_FAKE = 0.53f;
|
||||
|
||||
/**
|
||||
* @brief The SSCLoader handles all of the parsing needed for .ssc files.
|
||||
*/
|
||||
|
||||
@@ -273,11 +273,17 @@ static RString GetSMNotesTag( const Song &song, const Steps &in )
|
||||
lines.push_back( ssprintf( " %d:", in.GetMeter() ) );
|
||||
|
||||
vector<RString> asRadarValues;
|
||||
// SM files don't use fakes for radar data. Keep it that way.
|
||||
int categories = NUM_RadarCategory - 1;
|
||||
FOREACH_PlayerNumber( pn )
|
||||
{
|
||||
const RadarValues &rv = in.GetRadarValues( pn );
|
||||
FOREACH_ENUM( RadarCategory, rc )
|
||||
// Can't use the foreach anymore due to flexible radar lines.
|
||||
for( RadarCategory rc = (RadarCategory)0; rc < categories;
|
||||
enum_add<RadarCategory>( rc, 1 ) )
|
||||
{
|
||||
asRadarValues.push_back( ssprintf("%.3f", rv[rc]) );
|
||||
}
|
||||
}
|
||||
lines.push_back( ssprintf( " %s:", join(",",asRadarValues).c_str() ) );
|
||||
|
||||
|
||||
@@ -47,7 +47,7 @@ static RString BackgroundChangeToString( const BackgroundChange &bgc )
|
||||
* @param out the Song in question. */
|
||||
static void WriteGlobalTags( RageFile &f, const Song &out )
|
||||
{
|
||||
f.PutLine( ssprintf( "#VERSION:%.2f;", out.m_fVersion ) );
|
||||
f.PutLine( ssprintf( "#VERSION:%.2f;", STEPFILE_VERSION_NUMBER ) );
|
||||
f.PutLine( ssprintf( "#TITLE:%s;", SmEscape(out.m_sMainTitle).c_str() ) );
|
||||
f.PutLine( ssprintf( "#SUBTITLE:%s;", SmEscape(out.m_sSubTitle).c_str() ) );
|
||||
f.PutLine( ssprintf( "#ARTIST:%s;", SmEscape(out.m_sArtist).c_str() ) );
|
||||
|
||||
@@ -1364,7 +1364,7 @@ OptionRowHandler* OptionRowHandlerUtil::MakeSimple( const MenuRowDef &mr )
|
||||
|
||||
pHand->m_Def.m_sName = mr.sName;
|
||||
FontCharAliases::ReplaceMarkers( pHand->m_Def.m_sName ); // Allow special characters
|
||||
|
||||
|
||||
pHand->m_Def.m_vEnabledForPlayers.clear();
|
||||
if( mr.pfnEnabled? mr.pfnEnabled():mr.bEnabled )
|
||||
{
|
||||
|
||||
@@ -9,7 +9,11 @@
|
||||
class OptionsCursor : public ActorFrame
|
||||
{
|
||||
public:
|
||||
/** @brief Set up a default OptionsCursor. */
|
||||
OptionsCursor();
|
||||
/**
|
||||
* @brief Set up an OptionsCursor based on an existing copy.
|
||||
* @param cpy the OptionsCursor we are copying. */
|
||||
OptionsCursor( const OptionsCursor &cpy );
|
||||
|
||||
void Load( const RString &sMetricsGroup, bool bLoadCanGos );
|
||||
|
||||
+7
-7
@@ -1,5 +1,3 @@
|
||||
/* OptionsList - A popup options list. */
|
||||
|
||||
#ifndef SCREEN_OPTIONS_LIST_H
|
||||
#define SCREEN_OPTIONS_LIST_H
|
||||
|
||||
@@ -37,7 +35,7 @@ private:
|
||||
|
||||
ThemeMetric<float> ITEMS_SPACING_Y;
|
||||
};
|
||||
|
||||
/** @brief A popup options list. */
|
||||
class OptionsList: public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -51,10 +49,10 @@ public:
|
||||
|
||||
void Link( OptionsList *pLink ) { m_pLinked = pLink; }
|
||||
|
||||
// Show the top-level menu.
|
||||
/** @brief Show the top-level menu. */
|
||||
void Open();
|
||||
|
||||
// Close all menus (for menu timer).
|
||||
/** @brief Close all menus (for menu timer). */
|
||||
void Close();
|
||||
|
||||
void Input( const InputEventPlus &input );
|
||||
@@ -108,8 +106,10 @@ private:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Copyright (c) 2006 Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author 2006 Glenn Maynard (c)
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -26,6 +26,7 @@ static const char *PaneCategoryNames[] = {
|
||||
"Mines",
|
||||
"Hands",
|
||||
"Lifts",
|
||||
"Fakes",
|
||||
"MachineHighScore",
|
||||
"MachineHighName",
|
||||
"ProfileHighScore",
|
||||
@@ -206,6 +207,7 @@ void PaneDisplay::SetContent( PaneCategory c )
|
||||
case PaneCategory_Mines: val = rv[RadarCategory_Mines]; break;
|
||||
case PaneCategory_Hands: val = rv[RadarCategory_Hands]; break;
|
||||
case PaneCategory_Lifts: val = rv[RadarCategory_Lifts]; break;
|
||||
case PaneCategory_Fakes: val = rv[RadarCategory_Fakes]; break;
|
||||
case PaneCategory_ProfileHighScore:
|
||||
case PaneCategory_MachineHighName: // set val for color
|
||||
case PaneCategory_MachineHighScore:
|
||||
|
||||
@@ -22,6 +22,7 @@ enum PaneCategory
|
||||
PaneCategory_Mines,
|
||||
PaneCategory_Hands,
|
||||
PaneCategory_Lifts,
|
||||
PaneCategory_Fakes,
|
||||
PaneCategory_MachineHighScore,
|
||||
PaneCategory_MachineHighName,
|
||||
PaneCategory_ProfileHighScore,
|
||||
|
||||
+1
-3
@@ -593,9 +593,7 @@ void Player::Load()
|
||||
|
||||
// parameters are invalid somehow... -aj
|
||||
RageSoundLoadParams SoundParams;
|
||||
//RageSoundParams p;
|
||||
SoundParams.m_bSupportPan = true;
|
||||
//p.StopMode = RageSoundParams::M_STOP;
|
||||
|
||||
float fBalance = GameSoundManager::GetPlayerBalance( pn );
|
||||
for( unsigned i=0; i<m_vKeysounds.size(); i++ )
|
||||
@@ -605,7 +603,7 @@ void Player::Load()
|
||||
if( sound.GetLoadedFilePath() != sKeysoundFilePath )
|
||||
sound.Load( sKeysoundFilePath, true, &SoundParams );
|
||||
sound.SetProperty( "Pan", fBalance );
|
||||
//sound.SetParams( p );
|
||||
sound.SetStopModeFromString( "stop" );
|
||||
}
|
||||
|
||||
if( m_pPlayerStageStats )
|
||||
|
||||
@@ -214,6 +214,8 @@ void PlayerOptions::GetMods( vector<RString> &AddTo, bool bForceNoteSkin ) const
|
||||
if( m_bTransforms[TRANSFORM_HOLDROLLS] ) AddTo.push_back( "HoldsToRolls" );
|
||||
if( m_bTransforms[TRANSFORM_NOJUMPS] ) AddTo.push_back( "NoJumps" );
|
||||
if( m_bTransforms[TRANSFORM_NOHANDS] ) AddTo.push_back( "NoHands" );
|
||||
if( m_bTransforms[TRANSFORM_NOLIFTS] ) AddTo.push_back( "NoLifts" );
|
||||
if( m_bTransforms[TRANSFORM_NOFAKES] ) AddTo.push_back( "NoFakes" );
|
||||
if( m_bTransforms[TRANSFORM_NOQUADS] ) AddTo.push_back( "NoQuads" );
|
||||
if( m_bTransforms[TRANSFORM_NOSTRETCH] )AddTo.push_back( "NoStretch" );
|
||||
if( m_bMuteOnError ) AddTo.push_back( "MuteOnError" );
|
||||
@@ -407,6 +409,8 @@ bool PlayerOptions::FromOneModString( const RString &sOneMod, RString &sErrorOut
|
||||
else if( sBit == "norolls" ) m_bTransforms[TRANSFORM_NOROLLS] = on;
|
||||
else if( sBit == "nomines" ) m_bTransforms[TRANSFORM_NOMINES] = on;
|
||||
else if( sBit == "nostretch" ) m_bTransforms[TRANSFORM_NOSTRETCH] = on;
|
||||
else if( sBit == "nolifts" ) m_bTransforms[TRANSFORM_NOLIFTS] = on;
|
||||
else if( sBit == "nofakes" ) m_bTransforms[TRANSFORM_NOFAKES] = on;
|
||||
else if( sBit == "dark" ) SET_FLOAT( fDark )
|
||||
else if( sBit == "blind" ) SET_FLOAT( fBlind )
|
||||
else if( sBit == "cover" ) SET_FLOAT( fCover )
|
||||
@@ -693,6 +697,10 @@ bool PlayerOptions::IsEasierForSongAndSteps( Song* pSong, Steps* pSteps, PlayerN
|
||||
return true;
|
||||
if( m_bTransforms[TRANSFORM_NOJUMPS] && rv[RadarCategory_Jumps]>0 )
|
||||
return true;
|
||||
if( m_bTransforms[TRANSFORM_NOLIFTS] && rv[RadarCategory_Lifts]>0 )
|
||||
return true;
|
||||
if( m_bTransforms[TRANSFORM_NOFAKES] && rv[RadarCategory_Fakes]>0 )
|
||||
return true;
|
||||
if( m_bTransforms[TRANSFORM_NOSTRETCH] )
|
||||
return true;
|
||||
|
||||
@@ -787,6 +795,8 @@ RString PlayerOptions::GetSavedPrefsString() const
|
||||
SAVE( m_bTransforms[TRANSFORM_NOHANDS] );
|
||||
SAVE( m_bTransforms[TRANSFORM_NOQUADS] );
|
||||
SAVE( m_bTransforms[TRANSFORM_NOSTRETCH] );
|
||||
SAVE( m_bTransforms[TRANSFORM_NOLIFTS] );
|
||||
SAVE( m_bTransforms[TRANSFORM_NOFAKES] );
|
||||
SAVE( m_ScoreDisplay );
|
||||
SAVE( m_bMuteOnError );
|
||||
SAVE( m_sNoteSkin );
|
||||
@@ -818,11 +828,31 @@ void PlayerOptions::ResetPrefs( ResetPrefsType type )
|
||||
CPY( m_bTransforms[TRANSFORM_NOHANDS] );
|
||||
CPY( m_bTransforms[TRANSFORM_NOQUADS] );
|
||||
CPY( m_bTransforms[TRANSFORM_NOSTRETCH] );
|
||||
CPY( m_bTransforms[TRANSFORM_NOLIFTS] );
|
||||
CPY( m_bTransforms[TRANSFORM_NOFAKES] );
|
||||
// Don't clear this.
|
||||
// CPY( m_sNoteSkin );
|
||||
#undef CPY
|
||||
}
|
||||
|
||||
// lua start
|
||||
#include "LuaBinding.h"
|
||||
|
||||
/** @brief Allow Lua to have access to PlayerOptions. */
|
||||
class LunaPlayerOptions: public Luna<PlayerOptions>
|
||||
{
|
||||
public:
|
||||
DEFINE_METHOD( GetNoteSkin, m_sNoteSkin )
|
||||
|
||||
LunaPlayerOptions()
|
||||
{
|
||||
ADD_METHOD( GetNoteSkin );
|
||||
}
|
||||
};
|
||||
|
||||
LUA_REGISTER_CLASS( PlayerOptions )
|
||||
// lua end
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford, Glenn Maynard
|
||||
* All rights reserved.
|
||||
|
||||
+38
-27
@@ -1,5 +1,3 @@
|
||||
/* PlayerOptions - Per-player options that are not saved between sessions. */
|
||||
|
||||
#ifndef PLAYER_OPTIONS_H
|
||||
#define PLAYER_OPTIONS_H
|
||||
|
||||
@@ -7,10 +5,11 @@ class Course;
|
||||
class Song;
|
||||
class Steps;
|
||||
class Trail;
|
||||
struct lua_State;
|
||||
|
||||
#include "GameConstantsAndTypes.h"
|
||||
#include "PlayerNumber.h"
|
||||
|
||||
/** @brief Per-player options that are not saved between sessions. */
|
||||
class PlayerOptions
|
||||
{
|
||||
public:
|
||||
@@ -34,16 +33,19 @@ public:
|
||||
void ChooseRandomModifiers();
|
||||
bool ContainsTransformOrTurn() const;
|
||||
|
||||
// Lua
|
||||
void PushSelf( lua_State *L );
|
||||
|
||||
bool operator==( const PlayerOptions &other ) const;
|
||||
bool operator!=( const PlayerOptions &other ) const { return !operator==(other); }
|
||||
|
||||
|
||||
/** @brief The various acceleration mods. */
|
||||
enum Accel {
|
||||
ACCEL_BOOST,
|
||||
ACCEL_BRAKE,
|
||||
ACCEL_BOOST, /**< The arrows start slow, then zoom towards the targets. */
|
||||
ACCEL_BRAKE, /**< The arrows start fast, then slow down as they approach the targets. */
|
||||
ACCEL_WAVE,
|
||||
ACCEL_EXPAND,
|
||||
ACCEL_BOOMERANG,
|
||||
ACCEL_BOOMERANG, /**< The arrows start from above the targets, go down, then come back up. */
|
||||
NUM_ACCELS
|
||||
};
|
||||
enum Effect {
|
||||
@@ -63,24 +65,26 @@ public:
|
||||
EFFECT_ROLL,
|
||||
NUM_EFFECTS
|
||||
};
|
||||
/** @brief The various appearance mods. */
|
||||
enum Appearance {
|
||||
APPEARANCE_HIDDEN,
|
||||
APPEARANCE_HIDDEN_OFFSET,
|
||||
APPEARANCE_SUDDEN,
|
||||
APPEARANCE_SUDDEN_OFFSET,
|
||||
APPEARANCE_STEALTH,
|
||||
APPEARANCE_BLINK,
|
||||
APPEARANCE_RANDOMVANISH,
|
||||
APPEARANCE_HIDDEN, /**< The arrows disappear partway up. */
|
||||
APPEARANCE_HIDDEN_OFFSET, /**< This determines when the arrows disappear. */
|
||||
APPEARANCE_SUDDEN, /**< The arrows appear partway up. */
|
||||
APPEARANCE_SUDDEN_OFFSET, /**< This determines when the arrows appear. */
|
||||
APPEARANCE_STEALTH, /**< The arrows are not shown at all. */
|
||||
APPEARANCE_BLINK, /**< The arrows blink constantly. */
|
||||
APPEARANCE_RANDOMVANISH, /**< The arrows disappear, and then reappear in a different column. */
|
||||
NUM_APPEARANCES
|
||||
};
|
||||
/** @brief The various turn mods. */
|
||||
enum Turn {
|
||||
TURN_NONE=0,
|
||||
TURN_MIRROR,
|
||||
TURN_LEFT,
|
||||
TURN_RIGHT,
|
||||
TURN_SHUFFLE,
|
||||
TURN_SOFT_SHUFFLE,
|
||||
TURN_SUPER_SHUFFLE,
|
||||
TURN_NONE=0, /**< No turning of the arrows is performed. */
|
||||
TURN_MIRROR, /**< The arrows are mirrored from their normal position. */
|
||||
TURN_LEFT, /**< The arrows are turned 90 degrees to the left. */
|
||||
TURN_RIGHT, /**< The arrows are turned 90 degress to the right. */
|
||||
TURN_SHUFFLE, /**< Some of the arrow columns are changed throughout the whole song. */
|
||||
TURN_SOFT_SHUFFLE, /**< Only shuffle arrow columns on an axis of symmetry. */
|
||||
TURN_SUPER_SHUFFLE, /**< Every arrow is placed on a random column. */
|
||||
NUM_TURNS
|
||||
};
|
||||
enum Transform {
|
||||
@@ -103,6 +107,8 @@ public:
|
||||
TRANSFORM_HOLDROLLS,
|
||||
TRANSFORM_NOJUMPS,
|
||||
TRANSFORM_NOHANDS,
|
||||
TRANSFORM_NOLIFTS,
|
||||
TRANSFORM_NOFAKES,
|
||||
TRANSFORM_NOQUADS,
|
||||
TRANSFORM_NOSTRETCH,
|
||||
NUM_TRANSFORMS
|
||||
@@ -154,15 +160,21 @@ public:
|
||||
bool m_bTransforms[NUM_TRANSFORMS];
|
||||
bool m_bMuteOnError;
|
||||
ScoreDisplay m_ScoreDisplay;
|
||||
/** @brief How can the Player fail a song? */
|
||||
enum FailType {
|
||||
FAIL_IMMEDIATE=0, // fail immediately when life touches 0
|
||||
FAIL_IMMEDIATE_CONTINUE, // fail immediately when life touches 0, but allow playing the rest of the song
|
||||
FAIL_AT_END, // fail if life is at 0 when the song ends
|
||||
FAIL_OFF // never fail
|
||||
FAIL_IMMEDIATE=0, /**< fail immediately when life touches 0 */
|
||||
FAIL_IMMEDIATE_CONTINUE, /**< Same as above, but allow playing the rest of the song */
|
||||
FAIL_AT_END, /**< fail if life is at 0 when the song ends */
|
||||
FAIL_OFF /**< never fail */
|
||||
};
|
||||
/** @brief The method for which a player can fail a song. */
|
||||
FailType m_FailType;
|
||||
|
||||
RString m_sNoteSkin; // "" means "no change"
|
||||
/**
|
||||
* @brief The Noteskin to use.
|
||||
*
|
||||
* If an empty string, it means to not change from the default. */
|
||||
RString m_sNoteSkin;
|
||||
|
||||
void NextAccel();
|
||||
void NextEffect();
|
||||
@@ -183,7 +195,6 @@ public:
|
||||
void SetOneScroll( Scroll s );
|
||||
void ToggleOneTurn( Turn t );
|
||||
|
||||
|
||||
// return true if any mods being used will make the song(s) easier
|
||||
bool IsEasierForSongAndSteps( Song* pSong, Steps* pSteps, PlayerNumber pn ) const;
|
||||
bool IsEasierForCourseAndTrail( Course* pCourse, Trail* pTrail ) const;
|
||||
|
||||
@@ -187,7 +187,7 @@ Grade PlayerStageStats::GetGrade() const
|
||||
|
||||
//LOG->Trace( "GetGrade: Grade: %s, %i", GradeToString(grade).c_str(), GRADE_TIER02_IS_ALL_W2S );
|
||||
|
||||
// todo: move all these conditions to Lua. -aj
|
||||
// TODO: Change these conditions to use Lua instead. -aj
|
||||
if( GRADE_TIER02_IS_ALL_W2S )
|
||||
{
|
||||
if( FullComboOfScore(TNS_W1) )
|
||||
|
||||
+23
-10
@@ -1,5 +1,3 @@
|
||||
/* PlayerStageStats - Contains statistics for one stage of play - either one song, or a whole course. */
|
||||
|
||||
#ifndef PlayerStageStats_H
|
||||
#define PlayerStageStats_H
|
||||
|
||||
@@ -10,7 +8,7 @@
|
||||
#include <map>
|
||||
class Steps;
|
||||
struct lua_State;
|
||||
|
||||
/** @brief Contains statistics for one stage of play - either one song, or a whole course. */
|
||||
class PlayerStageStats
|
||||
{
|
||||
public:
|
||||
@@ -32,10 +30,18 @@ public:
|
||||
bool m_bJoined;
|
||||
vector<Steps*> m_vpPossibleSteps;
|
||||
int m_iStepsPlayed; // how many of m_vpPossibleStepshow many of m_vpPossibleSteps were played
|
||||
float m_fAliveSeconds; // how far into the music did they last before failing? Updated by Gameplay, scaled by music rate.
|
||||
/**
|
||||
* @brief How far into the music did the Player last before failing?
|
||||
*
|
||||
* This is updated by Gameplay, and scaled by the music rate. */
|
||||
float m_fAliveSeconds;
|
||||
|
||||
/* Set if the player actually failed at any point during the song. This is always
|
||||
* false in FAIL_OFF. If recovery is enabled and two players are playing,
|
||||
/**
|
||||
* @brief Have the Players failed at any point during the song?
|
||||
*
|
||||
* If FAIL_OFF is in use, this is always false.
|
||||
*
|
||||
* If health recovery is possible after failing (requires two players),
|
||||
* this is only set if both players were failing at the same time. */
|
||||
bool m_bFailed;
|
||||
|
||||
@@ -54,10 +60,15 @@ public:
|
||||
int m_iMaxScore;
|
||||
RadarValues m_radarPossible; // filled in by ScreenGameplay on start of notes
|
||||
RadarValues m_radarActual;
|
||||
// The number of songs played and passed, respectively.
|
||||
/** @brief How many songs were passed by the Player? */
|
||||
int m_iSongsPassed;
|
||||
/** @brief How many songs were played by the Player? */
|
||||
int m_iSongsPlayed;
|
||||
float m_fLifeRemainingSeconds; // used in survival
|
||||
/**
|
||||
* @brief How many seconds were left for the Player?
|
||||
*
|
||||
* This is used in the Survival mode. */
|
||||
float m_fLifeRemainingSeconds;
|
||||
|
||||
// workout
|
||||
float m_iNumControllerSteps;
|
||||
@@ -125,8 +136,10 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2004 Chris Danford, Glenn Maynard
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford, Glenn Maynard (c) 2001-2004
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
+10
-2
@@ -210,8 +210,8 @@ public:
|
||||
static int GetPlayerOptions( T* p, lua_State *L )
|
||||
{
|
||||
ModsLevel m = Enum::Check<ModsLevel>( L, 1 );
|
||||
RString s = p->m_PlayerOptions.Get(m).GetString();
|
||||
LuaHelpers::Push( L, s );
|
||||
PlayerOptions po = p->m_PlayerOptions.Get(m);
|
||||
po.PushSelf(L);
|
||||
return 1;
|
||||
}
|
||||
static int GetPlayerOptionsArray( T* p, lua_State *L )
|
||||
@@ -222,6 +222,13 @@ public:
|
||||
LuaHelpers::CreateTableFromArray<RString>( s, L );
|
||||
return 1;
|
||||
}
|
||||
static int GetPlayerOptionsString( T* p, lua_State *L )
|
||||
{
|
||||
ModsLevel m = Enum::Check<ModsLevel>( L, 1 );
|
||||
RString s = p->m_PlayerOptions.Get(m).GetString();
|
||||
LuaHelpers::Push( L, s );
|
||||
return 1;
|
||||
}
|
||||
DEFINE_METHOD( GetHealthState, m_HealthState );
|
||||
|
||||
LunaPlayerState()
|
||||
@@ -231,6 +238,7 @@ public:
|
||||
ADD_METHOD( SetPlayerOptions );
|
||||
ADD_METHOD( GetPlayerOptions );
|
||||
ADD_METHOD( GetPlayerOptionsArray );
|
||||
ADD_METHOD( GetPlayerOptionsString );
|
||||
ADD_METHOD( GetHealthState );
|
||||
}
|
||||
};
|
||||
|
||||
+5
-1
@@ -31,7 +31,11 @@ public:
|
||||
* in PlayerState and callers should not use PlayerNumber to index into
|
||||
* GameState. */
|
||||
PlayerNumber m_PlayerNumber;
|
||||
|
||||
/**
|
||||
* @brief The MultiPlayer number assigned to this Player, typically 1-32.
|
||||
*
|
||||
* This is only used if GAMESTATE->m_bMultiplayer is true.
|
||||
*/
|
||||
MultiPlayer m_mp;
|
||||
|
||||
/**
|
||||
|
||||
+20
-7
@@ -1,5 +1,3 @@
|
||||
/** @brief Profile - Player data that persists between sessions. Can be stored on a local disk or on a memory card. */
|
||||
|
||||
#ifndef Profile_H
|
||||
#define Profile_H
|
||||
|
||||
@@ -62,7 +60,10 @@ class Song;
|
||||
class Steps;
|
||||
class Course;
|
||||
class Game;
|
||||
|
||||
/**
|
||||
* @brief Player data that persists between sessions.
|
||||
*
|
||||
* This can be stored on a local disk or on a memory card. */
|
||||
class Profile
|
||||
{
|
||||
public:
|
||||
@@ -95,14 +96,20 @@ public:
|
||||
Song *GetMostPopularSong() const;
|
||||
Course *GetMostPopularCourse() const;
|
||||
|
||||
void AddStepTotals( int iNumTapsAndHolds, int iNumJumps, int iNumHolds, int iNumRolls, int iNumMines, int iNumHands, int iNumLifts, float fCaloriesBurned );
|
||||
void AddStepTotals( int iNumTapsAndHolds, int iNumJumps, int iNumHolds, int iNumRolls, int iNumMines,
|
||||
int iNumHands, int iNumLifts, float fCaloriesBurned );
|
||||
|
||||
bool IsMachine() const;
|
||||
|
||||
// Editable data
|
||||
RString m_sDisplayName;
|
||||
RString m_sCharacterID;
|
||||
RString m_sLastUsedHighScoreName; // this doesn't really belong in "editable", but we need it in the smaller editable file so that it can be ready quickly.
|
||||
/**
|
||||
* @brief The last used name for high scoring purposes.
|
||||
*
|
||||
* This really shouldn't be in "editable", but it's needed in the smaller editable file
|
||||
* so that it can be ready quickly. */
|
||||
RString m_sLastUsedHighScoreName;
|
||||
int m_iWeightPounds; // 0 == not set
|
||||
//RString m_sProfileImageName; // todo: add a default image -aj
|
||||
|
||||
@@ -136,7 +143,13 @@ public:
|
||||
int m_iTotalHands;
|
||||
int m_iTotalLifts;
|
||||
set<RString> m_UnlockedEntryIDs;
|
||||
mutable RString m_sLastPlayedMachineGuid; // mutable because we overwrite this on save, and I don't want to remove const from the whole save chain. -Chris
|
||||
/**
|
||||
* @brief Which machine did we play on last, based on the Guid?
|
||||
*
|
||||
* This is mutable because it's overwritten on save, but is usually
|
||||
* const everywhere else. It was decided to keep const on the whole
|
||||
* save chain and keep this mutable. -Chris */
|
||||
mutable RString m_sLastPlayedMachineGuid;
|
||||
mutable DateTime m_LastPlayedDate;
|
||||
/* These stats count twice in the machine profile if two players are playing;
|
||||
* that's the only approach that makes sense for ByDifficulty and ByMeter. */
|
||||
@@ -217,7 +230,7 @@ public:
|
||||
|
||||
|
||||
/**
|
||||
* @brief The basics for Calorie Data
|
||||
* @brief The basics for Calorie Data.
|
||||
*
|
||||
* Why track calories in a map, and not in a static sized array like
|
||||
* Bookkeeping? The machine's clock is not guaranteed to be set correctly.
|
||||
|
||||
+1
-3
@@ -1,11 +1,9 @@
|
||||
/** @brief Quad - A rectangle shaped actor with color. */
|
||||
|
||||
#ifndef QUAD_H
|
||||
#define QUAD_H
|
||||
|
||||
#include "Sprite.h"
|
||||
|
||||
/** @brief the Rectangular Actor with color. */
|
||||
/** @brief A rectangular shaped Actor with color. */
|
||||
class Quad : public Sprite
|
||||
{
|
||||
public:
|
||||
|
||||
+2
-3
@@ -1,5 +1,3 @@
|
||||
/** @brief RadarValues - Cached song statistics. */
|
||||
|
||||
#ifndef RARAR_VALUES_H
|
||||
#define RARAR_VALUES_H
|
||||
|
||||
@@ -11,7 +9,7 @@
|
||||
|
||||
class XNode;
|
||||
struct lua_State;
|
||||
/** @brief The collection of radar values. */
|
||||
/** @brief Cached song statistics. */
|
||||
struct RadarValues
|
||||
{
|
||||
union Values
|
||||
@@ -30,6 +28,7 @@ struct RadarValues
|
||||
float fNumHands;
|
||||
float fNumRolls;
|
||||
float fNumLifts;
|
||||
float fNumFakes;
|
||||
} v;
|
||||
float f[NUM_RadarCategory];
|
||||
} m_Values;
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
/* ReceptorArrowRow - A row of ReceptorArrow objects. */
|
||||
|
||||
#ifndef RECEPTOR_ARROW_ROW_H
|
||||
#define RECEPTOR_ARROW_ROW_H
|
||||
|
||||
@@ -8,7 +6,7 @@
|
||||
#include "GameConstantsAndTypes.h"
|
||||
|
||||
class PlayerState;
|
||||
|
||||
/** @brief A row of ReceptorArrow objects. */
|
||||
class ReceptorArrowRow : public ActorFrame
|
||||
{
|
||||
public:
|
||||
@@ -35,8 +33,10 @@ protected:
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2001-2003 Chris Danford
|
||||
/**
|
||||
* @file
|
||||
* @author Chris Danford (c) 2001-2003
|
||||
* @section LICENSE
|
||||
* All rights reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
/** @brief RollingNumbers - animates from one number to another by scrolling its digits. */
|
||||
|
||||
#ifndef RollingNumbers_H
|
||||
#define RollingNumbers_H
|
||||
|
||||
#include "BitmapText.h"
|
||||
#include "ThemeMetric.h"
|
||||
|
||||
/** @brief Animates from one number to another by scrolling its digits. */
|
||||
class RollingNumbers : public BitmapText
|
||||
{
|
||||
public:
|
||||
|
||||
@@ -1027,6 +1027,8 @@ static LocalizedString HANDS("ScreenEdit", "Hands");
|
||||
static LocalizedString HOLDS("ScreenEdit", "Holds");
|
||||
static LocalizedString MINES("ScreenEdit", "Mines");
|
||||
static LocalizedString ROLLS("ScreenEdit", "Rolls");
|
||||
static LocalizedString LIFTS("ScreenEdit", "Lifts");
|
||||
static LocalizedString FAKES("ScreenEdit", "Fakes");
|
||||
static LocalizedString BEAT_0_OFFSET("ScreenEdit", "Beat 0 offset");
|
||||
static LocalizedString PREVIEW_START("ScreenEdit", "Preview Start");
|
||||
static LocalizedString PREVIEW_LENGTH("ScreenEdit", "Preview Length");
|
||||
@@ -1049,6 +1051,8 @@ static ThemeMetric<RString> NUM_HOLDS_FORMAT("ScreenEdit", "NumHoldsFormat");
|
||||
static ThemeMetric<RString> NUM_MINES_FORMAT("ScreenEdit", "NumMinesFormat");
|
||||
static ThemeMetric<RString> NUM_HANDS_FORMAT("ScreenEdit", "NumHandsFormat");
|
||||
static ThemeMetric<RString> NUM_ROLLS_FORMAT("ScreenEdit", "NumRollsFormat");
|
||||
static ThemeMetric<RString> NUM_LIFTS_FORMAT("ScreenEdit", "NumLiftsFormat");
|
||||
static ThemeMetric<RString> NUM_FAKES_FORMAT("ScreenEdit", "NumFakesFormat");
|
||||
static ThemeMetric<RString> BEAT_0_OFFSET_FORMAT("ScreenEdit", "Beat0OffsetFormat");
|
||||
static ThemeMetric<RString> PREVIEW_START_FORMAT("ScreenEdit", "PreviewStartFormat");
|
||||
static ThemeMetric<RString> PREVIEW_LENGTH_FORMAT("ScreenEdit", "PreviewLengthFormat");
|
||||
@@ -1117,6 +1121,8 @@ void ScreenEdit::UpdateTextInfo()
|
||||
sText += ssprintf( NUM_HOLDS_FORMAT.GetValue(), HOLDS.GetValue().c_str(), m_NoteDataEdit.GetNumHoldNotes() );
|
||||
sText += ssprintf( NUM_MINES_FORMAT.GetValue(), MINES.GetValue().c_str(), m_NoteDataEdit.GetNumMines() );
|
||||
sText += ssprintf( NUM_ROLLS_FORMAT.GetValue(), ROLLS.GetValue().c_str(), m_NoteDataEdit.GetNumRolls() );
|
||||
sText += ssprintf( NUM_LIFTS_FORMAT.GetValue(), LIFTS.GetValue().c_str(), m_NoteDataEdit.GetNumLifts() );
|
||||
sText += ssprintf( NUM_FAKES_FORMAT.GetValue(), FAKES.GetValue().c_str(), m_NoteDataEdit.GetNumFakes() );
|
||||
switch( EDIT_MODE.GetValue() )
|
||||
{
|
||||
DEFAULT_FAIL( EDIT_MODE.GetValue() );
|
||||
|
||||
@@ -198,6 +198,7 @@ void ScreenEvaluation::Init()
|
||||
case RadarCategory_Hands:
|
||||
case RadarCategory_Rolls:
|
||||
case RadarCategory_Lifts:
|
||||
case RadarCategory_Fakes:
|
||||
ss.m_player[p].m_radarPossible[rc] = 1 + (rand() % 200);
|
||||
ss.m_player[p].m_radarActual[rc] = rand() % (int)(ss.m_player[p].m_radarPossible[rc]);
|
||||
break;
|
||||
@@ -541,8 +542,8 @@ void ScreenEvaluation::Init()
|
||||
|
||||
static const int indeces[NUM_DetailLine] =
|
||||
{
|
||||
RadarCategory_TapsAndHolds, RadarCategory_Jumps, RadarCategory_Holds, RadarCategory_Mines, RadarCategory_Hands, RadarCategory_Rolls
|
||||
//, RadarCategory_Lifts
|
||||
RadarCategory_TapsAndHolds, RadarCategory_Jumps, RadarCategory_Holds, RadarCategory_Mines,
|
||||
RadarCategory_Hands, RadarCategory_Rolls, RadarCategory_Lifts, RadarCategory_Fakes
|
||||
};
|
||||
const int ind = indeces[l];
|
||||
const int iActual = lrintf(m_pStageStats->m_player[p].m_radarActual[ind]);
|
||||
|
||||
@@ -41,6 +41,8 @@ enum DetailLine
|
||||
DetailLine_Mines, /**< The number of mines avoided. */
|
||||
DetailLine_Hands, /**< The number of hands hit (somehow) */
|
||||
DetailLine_Rolls, /**< The number of rolls hit repeatedly. */
|
||||
DetailLine_Lifts, /**< The number of lifts lifted up. */
|
||||
DetailLine_Fakes, /**< The number of fakes to be ignored. */
|
||||
NUM_DetailLine /**< The nuber of detailed lines. */
|
||||
};
|
||||
/** @brief Shows the player their score after gameplay has ended. */
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user