Merge branch '5_1-new' of https://github.com/stepmania/stepmania into 5_1-new

This commit is contained in:
ListenerJubatus
2018-01-18 19:20:01 -06:00
8 changed files with 22 additions and 4 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

+5
View File
@@ -0,0 +1,5 @@
[Global]
FallbackNoteSkin=midi-solo
[NoteDisplay]
TapNoteNoteColorType=ProgressAlternate
+1 -1
View File
@@ -1,6 +1,6 @@
return Def.Sprite {
Texture=NOTESKIN:GetPath( '_down', 'tap note' );
Frames = Sprite.LinearFrames( 8, 1 );
Frames = Sprite.LinearFrames( 4, 1 );
InitCommand=cmd(setstate,2);
DrawTapNoteMessageCommand=function(self,parent)
parent:spin();
Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

+4 -3
View File
@@ -3,6 +3,7 @@ FallbackNoteSkin=midi-note
[NoteDisplay]
TapNoteAnimationIsVivid=0
TapNoteNoteColorCount=4
DrawHoldHeadForTapsOnSameRow=0
TapNoteAnimationLength=4
TapAdditionAnimationLength=4
@@ -29,10 +30,10 @@ FlipHoldBodyWhenReverse=1
TopHoldAnchorWhenReverse=1
TapNoteNoteColorTextureCoordSpacingX=0
TapNoteNoteColorTextureCoordSpacingY=0.125
TapNoteNoteColorTextureCoordSpacingY=0.25
TapFakeNoteColorTextureCoordSpacingX=0
TapFakeNoteColorTextureCoordSpacingY=0.125
TapFakeNoteColorTextureCoordSpacingY=0.25
HoldHeadNoteColorTextureCoordSpacingX=0
HoldHeadNoteColorTextureCoordSpacingY=0
@@ -78,4 +79,4 @@ PressCommand=stoptweening;zoom,1.15;linear,0.12;zoom,1
[ReceptorOverlay]
InitCommand=diffusealpha,0;blend,"BlendMode_Add"
PressCommand=finishtweening;zoom,1.1;decelerate,0.12;zoom,1;diffusealpha,0.6;
LiftCommand=finishtweening;accelerate,0.12;diffusealpha,0;zoom,1.2
LiftCommand=finishtweening;accelerate,0.12;diffusealpha,0;zoom,1.2
+11
View File
@@ -41,6 +41,7 @@ LuaXType( NotePart );
static const char *NoteColorTypeNames[] = {
"Denominator",
"Progress",
"ProgressAlternate"
};
XToString( NoteColorType );
StringToX( NoteColorType );
@@ -1325,6 +1326,8 @@ void NoteDisplay::DrawActor(const TapNote& tn, Actor* pActor, NotePart part,
{
DISPLAY->TexturePushMatrix();
float color = 0.0f;
//this is only used for ProgressAlternate but must be declared here
float fScaledBeat = 0.0f;
switch( cache->m_NoteColorType[part] )
{
case NoteColorType_Denominator:
@@ -1334,6 +1337,14 @@ void NoteDisplay::DrawActor(const TapNote& tn, Actor* pActor, NotePart part,
case NoteColorType_Progress:
color = fmodf( ceilf( fBeat * cache->m_iNoteColorCount[part] ), (float)cache->m_iNoteColorCount[part] );
break;
case NoteColorType_ProgressAlternate:
fScaledBeat = fBeat * cache->m_iNoteColorCount[part];
if( fScaledBeat - int64_t(fScaledBeat) == 0.0f )
//we're on a boundary, so move to the previous frame.
//doing it this way ensures that fScaledBeat is never negative so fmodf works.
fScaledBeat += cache->m_iNoteColorCount[part] - 1;
color = fmodf( ceilf( fScaledBeat ), (float)cache->m_iNoteColorCount[part] );
break;
default:
FAIL_M(ssprintf("Invalid NoteColorType: %i", cache->m_NoteColorType[part]));
}
+1
View File
@@ -36,6 +36,7 @@ enum NoteColorType
{
NoteColorType_Denominator, /**< Color by note type. */
NoteColorType_Progress, /**< Color by progress. */
NoteColorType_ProgressAlternate, /**< Color by progress, except the frame boundaries are slightly later. */
NUM_NoteColorType,
NoteColorType_Invalid
};