Commit Graph
100 Commits
Author SHA1 Message Date
Glenn Maynard d87cfccfb9 simplify 2005-10-11 00:48:27 +00:00
Glenn Maynard 92585fcaa9 rearrange 2005-10-11 00:47:15 +00:00
Glenn Maynard 2d4cd30865 hide templates 2005-10-10 22:33:08 +00:00
Glenn Maynard 610262a46c use standard load path, not ActorUtil::LoadFromActorFile directly 2005-10-10 22:27:09 +00:00
Glenn Maynard 0f17b0f9c2 Actor::IsType 2005-10-10 21:52:04 +00:00
Glenn Maynard a69244f41f Take a path to ActorUtil::MakeActor, not a RageTextureID. Nothing uses it
here.
2005-10-10 20:55:47 +00:00
Glenn Maynard 5c13eb7d35 Oops. Actor::LoadFromNode wasn't virtual, but we were treating it as if
it was (BitmapText::LoadFromNode, etc. called it).  This worked because
REGISTER_ACTOR_CLASS called it before the object was downcasted to an Actor.
We then re-called Actor::LoadFromNode from ActorUtil::LoadFromActorFile;
this worked because all it did was re-run Actor init (causing double
calls to Init) and not the whole actor.

(first half fix: make Actor::LoadFromNode virtual and add comment)
2005-10-10 08:23:00 +00:00
Glenn Maynard eef0ed7ffb typo 2005-10-10 07:21:43 +00:00
Glenn Maynard 766b7d8045 cleanup 2005-10-10 06:06:42 +00:00
Glenn Maynard d5b5ca9287 cleanup 2005-10-10 04:52:58 +00:00
Glenn Maynard 1a3d247dbf simplify: m_bGameplayLeadIn is regular state, not music state; reset in Reset(),
not ResetMusicStatistics
2005-10-10 04:50:53 +00:00
Glenn Maynard 49b7d0bcbe m_bGameplayLeadIn 2005-10-10 04:39:32 +00:00
Glenn Maynard 97fc487d36 m_bPastHereWeGo 2005-10-10 04:37:23 +00:00
Glenn Maynard 1168414cf0 m_bPastHereWeGo -> !m_bGameplayLeadIn, default false. This is more natural;
!m_bPastHereWeGo was the usual case.
2005-10-10 04:36:04 +00:00
Glenn Maynard 7efd17ad8f fix messages never processed in ReceptorArrowRow/GhostArrowRow 2005-10-10 04:07:21 +00:00
Glenn Maynard c2da47d357 fix messages never processed in NoteField 2005-10-10 04:06:37 +00:00
Glenn Maynard 3b32e9d0d2 fix update done twice 2005-10-10 03:57:09 +00:00
Glenn Maynard b0df6d2d68 broadcast bPastHereWeGo 2005-10-10 02:24:58 +00:00
Glenn Maynard eaf7899a1c stoptweening in metrics, not code 2005-10-10 01:26:08 +00:00
Glenn Maynard 19a5aa6cbd remove unused 2005-10-09 01:52:45 +00:00
Glenn Maynard 797653e5a4 better encapsulation 2005-10-09 01:36:04 +00:00
Glenn Maynard 9525bc094d prefer to init cached metrics from Init, not ctor 2005-10-07 03:28:47 +00:00
Glenn Maynard fee7293c08 allow initting these with Load 2005-10-07 03:28:16 +00:00
Glenn Maynard 8fb283a59c move assert to Read() 2005-10-07 03:24:22 +00:00
Glenn Maynard 0ca0b6a43f add GetName, GetGroup 2005-10-07 03:20:40 +00:00
Glenn Maynard 952270b060 use Init
cleanup
2005-10-07 03:07:17 +00:00
Glenn Maynard 1b319be859 done automatically 2005-10-07 03:00:01 +00:00
Glenn Maynard abc2595e45 simplify 2005-10-07 02:57:54 +00:00
Glenn Maynard a411c9d1f4 comment 2005-10-07 02:56:23 +00:00
Glenn Maynard 91815ef03e Simplify: Move LoadChildrenFromNode into ActorFrame::LoadFromNode.
This also makes loading consistent between ActorFrame, ActorScroller and DActorScroller.
Previously, we ran ActorFrame::LoadFromNode before adding children, which caused InitCommand
to be run before adding children.
2005-10-07 02:55:47 +00:00
Glenn Maynard f875098dac typo 2005-10-07 02:44:42 +00:00
Glenn Maynard de8b1db0f3 typo 2005-10-07 02:00:42 +00:00
Glenn Maynard 7a8cf0bb38 cleanup: move code out of header, remove RageUtil.h from Actor.h 2005-10-07 01:59:20 +00:00
Glenn Maynard 630ea78f63 missing header 2005-10-07 01:58:41 +00:00
Glenn Maynard 775273cef4 fix warning 2005-10-07 01:45:48 +00:00
Glenn Maynard c904417448 missing header 2005-10-07 01:45:20 +00:00
Glenn Maynard 0c0c5d9557 update 2005-10-07 01:39:34 +00:00
Glenn Maynard 4aa3330211 Nothing ever overrides BeginDraw or EndDraw--any time where we might, we just
do the stuff in DrawPrimitives.  Remove unneeded virtual calls from the Actor
draw path.

Fix comments.
2005-10-07 01:31:27 +00:00
Glenn Maynard 1472cd1618 old comment 2005-10-06 04:39:30 +00:00
Glenn Maynard f0fd4d8acc these mappings aren't really important here; these are just generic difficulty levels 2005-10-06 01:55:25 +00:00
Glenn Maynard 9217d8b333 update 2005-10-06 01:29:02 +00:00
Glenn Maynard 3e964691e5 remove GhostArrow 2005-10-06 01:28:22 +00:00
Glenn Maynard c3129a682e Remove GhostArrow, and do them with XML. This is simpler and reduces bloat
in note skins.
 - skins with only one ghost flash can simply override "Common Tap Explosion Bright"
   and "Dim"
 - don't need to have tons of files to redirect each type of ghost flash
 - still supports overriding ghost commands in NoteSkin metrics.ini
 - fixes obscure bug: the first bright ghost flash wouldn't hide the last dim ghost flash
2005-10-06 01:22:18 +00:00
Glenn Maynard 1ab2e6022e fixup 2005-10-06 01:16:42 +00:00
Glenn Maynard 3c212785c0 remove unused Unload 2005-10-06 01:16:05 +00:00
Glenn Maynard 757b5c0acb prefer AutoActor over Sprite 2005-10-05 22:36:49 +00:00
Glenn Maynard a3c0817d81 prefer AutoActor over Sprite 2005-10-05 22:30:54 +00:00
Glenn Maynard c411e8a4ac fix name conflict between HoldJudgment::Reset and Actor::Reset
prefer AutoActor over Sprite
2005-10-05 22:26:02 +00:00
Glenn Maynard 363f995814 Fix HoldJudgments not being shown. Actors can't be stored in STL containers
without implementing operator= and a copy ctor; the ActorFrame child list
won't be updated.  (This used to work because, with a fixed-length array,
this loading was done in the ctor, though it should have been done in Init.)  Also
fixes loads happening during Player::Load, which shouldn't happen.
2005-10-05 22:21:27 +00:00
Glenn Maynard 291696fc1f fix backwards 2005-10-05 22:14:48 +00:00
Glenn Maynard 56720f74b8 fix HOLD_JUDGMENTS_UNDER_FIELD 2005-10-05 22:05:47 +00:00
Glenn Maynard 9f8e27442c fix name conflict between HoldJudgment::Reset and Actor::Reset 2005-10-05 22:03:47 +00:00
Glenn Maynard d78b194f09 add GetAnimationLengthSeconds 2005-10-05 08:31:46 +00:00
Glenn Maynard 4cbf9be85a Add AddCommand and THEME:GetMetricA.
This won't work with theme reloading, but that hasn't worked in a long time anyway
(recreating the Lua environment while it's actually in use is hard).
2005-10-05 07:37:26 +00:00
Glenn Maynard 4e312a4ffd cleanup 2005-10-05 06:13:57 +00:00
Glenn Maynard f723499700 make this behave consistently with THEME:GetPath when given a blank
button name
2005-10-05 06:05:53 +00:00
Glenn Maynard 73fffe0bde unused 2005-10-05 05:56:17 +00:00
Glenn Maynard a5cf8c21b0 cleanup 2005-10-05 05:49:50 +00:00
Glenn Maynard d1c457601f cleanup 2005-10-05 05:25:20 +00:00
Glenn Maynard b76d363994 Remove ugly CopyTweening. This is too wildly incompatible with newer
XML features, where there's not necessarily any corrolation between elements
of different graphics.  This didn't work well, anyway: it'd apply the old tweening
queue to the new graphics, but they might have completely different animations.
This will cause transitions between NoteSkins to be more abrupt, but we don't
use that feature anyway.
2005-10-05 04:49:09 +00:00
Glenn Maynard 829b581a9b fix "conversion from 'NoteType' to 'float', possible loss of data" 2005-10-04 20:32:11 +00:00
Glenn Maynard 57153b6c6c All of these should be played during silent attract (except for Invalid). Remove
volume setting (that was the same as m_bIsCriticalSound).
2005-10-04 07:47:15 +00:00
Glenn Maynard 9b41085586 fix IsTimeToPlayAttractSounds 2005-10-04 07:44:38 +00:00
Glenn Maynard bc85c365ee cleanup 2005-10-04 07:44:06 +00:00
Glenn Maynard 1cdfffd6a7 Let's be explicit: Demonstration should act like an attract screen. (This usually
happens to work without this, because the previous attract screen will set it,
and won't unset it since that's done in input.)
2005-10-04 07:43:42 +00:00
Glenn Maynard 510f214792 unmute first, so Cancel gets to play sounds 2005-10-04 07:40:00 +00:00
Glenn Maynard c9a12177d8 fix backwards 2005-10-04 07:39:03 +00:00
Glenn Maynard 643da8e2ce Apply m_bIsCriticalSound permanently on play, so we don't start playing previously
muted sounds when GetPlayOnlyCriticalSounds changes.  Fixes background music
playing for a split second in some sound drivers when start is pressed during attract.
2005-10-04 07:35:35 +00:00
Glenn Maynard f88e38a788 "warning C4018: '>=' : signed/unsigned mismatch" 2005-10-04 07:21:49 +00:00
Glenn Maynard b5b224ee38 fix "warning C4213: nonstandard extension used : cast on l-value" 2005-10-04 07:20:52 +00:00
Glenn Maynard f0998a1dc5 store /sys/block name in Linux 2005-10-03 07:17:09 +00:00
Glenn Maynard e844ff7c32 By default, don't use item numbers. On scrollers with lots of items, especially
with Subdivisions > 1, m_exprTransformFunction uses too much memory, and
very few scrollers use this.  Usually, per-item effects can be done better by
using DynamicActorScroller and doing the effects on item load (but this can
do some things that can't).
2005-10-03 00:02:41 +00:00
Glenn Maynard eccfe81012 fix current StepsType ignored 2005-10-01 01:03:08 +00:00
Glenn Maynard 08bbfd215d work around VC brain damage 2005-09-29 06:35:30 +00:00
Glenn Maynard 9a86f82a15 partial compile fix 2005-09-29 06:23:39 +00:00
Glenn Maynard b8accdb7ec compile fix 2005-09-29 06:19:45 +00:00
Glenn Maynard d05224c544 increase timeout 2005-09-29 02:36:10 +00:00
Glenn Maynard 87ddfb4c41 Up until now, we've been backing up profile data by copying it to the
backup directory immediately after a successful load.  This ensures that
the data we're copying is valid, so after a successful copy, the backup
is valid, too.  This has a couple problems:

 - Copying takes a while.  It's much faster to move data.
 - Data shouldn't be written during a profile read.  Players should be able
   to assume that it's safe to remove the memory card at any time except
   when the game is explicitly saving.
 - Copying good data from one place to another is just as prone to error as
   initially writing it.  It's at least as easy for the backup copy to fail
   and result in a bad backup as it is for a save to fail in the first place.

Instead, when we successfully load profile data (and not from a backup),
set a flag.  Later, when we save over that data, we'll clear the flag and
move the data we're about to overwrite to the backup.
2005-09-29 00:33:22 +00:00
Glenn Maynard 14ab43b2aa RageFileManager::MoveFile 2005-09-28 23:00:34 +00:00
Glenn Maynard 04ec4e66f4 add optional RageFileDriver::MoveFile override; implement for RageFileDriverDirect and RageFileDriverTimeout 2005-09-28 22:59:12 +00:00
Glenn Maynard ca1309c49d basealpha 2005-09-28 03:50:00 +00:00
Glenn Maynard c4150955bd split ScreenRanking specializations into ScreenRankingScroller (for
PAGE_TYPE_ALL_STEPS, PAGE_TYPE_*_COURSES) and ScreenRankingLines
(PAGE_TYPE_CATEGORY, PAGE_TYPE_TRAIL).

Use DynamicActorScroller for ScreenRankingScroller; reduces overhead
significantly.
2005-09-27 19:10:09 +00:00
Glenn Maynard b5006f6e09 cleanup weird includes 2005-09-27 19:01:53 +00:00
Glenn Maynard aab04cc13f update 2005-09-27 18:14:17 +00:00
Glenn Maynard 34116d9f36 DynamicActorScroller 2005-09-27 18:13:00 +00:00
Glenn Maynard ab8ed823b6 add experimental DynamicActorScroller. This allows creating lists like
ScreenCredits and ScreenRanking without constructing dozens or hundreds
of actors, which saves a lot of memory and is easier to manipulate.  This could
also be used to support CourseContentsLists for long courses cheaply, etc.
2005-09-27 07:55:14 +00:00
Glenn Maynard 18f40a2b8f Separate "number of Actors" from "number of items": allow having more items than
actors.  Derived classes do this by overriding ShiftSubActors and setting m_iNumItems
to something other than m_SubActors.size().
2005-09-27 07:49:12 +00:00
Glenn Maynard 384e26cbec ActorScroller doesn't SetDestinationItem anymore, but we still want this here and not in ActorScroller. 2005-09-27 07:40:34 +00:00
Glenn Maynard 4ae883a5c6 cleanup 2005-09-27 07:34:45 +00:00
Glenn Maynard 75484e193f cleanup: add children before calling Load 2005-09-27 05:40:09 +00:00
Glenn Maynard 71931135a3 implement BitmapText::operator= 2005-09-27 05:38:14 +00:00
Glenn Maynard cc737b0835 fix message 2005-09-27 03:32:14 +00:00
Glenn Maynard 71ad5179b4 Don't scroll by default; do it in OnCommand. 2005-09-27 03:20:07 +00:00
Glenn Maynard e1cf2c5484 add lua bindings 2005-09-27 03:18:57 +00:00
Glenn Maynard 2436ef26db simplify 2005-09-26 23:01:24 +00:00
Glenn Maynard e3d5437031 fix up names 2005-09-26 21:04:02 +00:00
Glenn Maynard 5ca840d259 simplify algebraically; nudge both cases to look the same 2005-09-26 21:03:09 +00:00
Glenn Maynard 9110303bff equivalent and easier to understand: fCurrentItem is simply centered 2005-09-26 20:43:45 +00:00
Glenn Maynard e24e9d8c99 cleanup 2005-09-26 19:53:11 +00:00
Glenn Maynard 1178d1df75 cleanup 2005-09-26 19:52:04 +00:00