Commit Graph
182 Commits
Author SHA1 Message Date
Glenn Maynard 1d186c481d const fix 2006-01-15 07:12:05 +00:00
Chris Danford 353e0c5b6e break up arch stuff into smaller .cpp files to fix smpackage build and not pull in unnecessary stuff 2005-12-16 04:16:09 +00:00
Glenn Maynard 0a961c49c8 Revert cropping. "scaletocover,0,0,SCREEN_WIDTH,SCREEN_HEIGHT"
achieves the same effect.
2005-11-30 23:29:16 +00:00
Glenn Maynard 76f05625d5 ZoomToWidth/ZoomToHeight obeys crop. This way,
CropToAspectRatio,16/9;
  ZoomToWidth,SCREEN_WIDTH;
  ZoomToHeight,SCREEN_HEIGHT
will zoom to the center 16:9 area of the image.
2005-11-30 23:11:31 +00:00
Glenn Maynard c607f34d3a add Actor::CropToAspectRatio 2005-11-30 23:02:22 +00:00
Glenn Maynard 17efa3412d Actor::Reset() -> private Actor::InitDefaults(). 2005-10-16 02:22:33 +00:00
Glenn Maynard 64504718d1 move m_sCommandName from TS to TI. Cleaner, and fixes queued commands being wiped
out by LuaExpressionTransform.
2005-10-14 01:46:00 +00:00
Glenn Maynard 0f17b0f9c2 Actor::IsType 2005-10-10 21:52:04 +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 7a8cf0bb38 cleanup: move code out of header, remove RageUtil.h from Actor.h 2005-10-07 01:59:20 +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 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
Chris Danford 3ad4d519ba default bob and bounce in y, not in z 2005-08-29 15:27:18 +00:00
Glenn Maynard 1c81bcc5fc EarlyAbortDraw() const 2005-08-25 00:57:53 +00:00
Chris Danford 639bf366a9 fix GCC warning 2005-08-16 18:23:25 +00:00
Chris Danford c885d87f4a Use a lua transform function to position SOptions rows instead of having a Y metric for each row 2005-08-15 07:51:16 +00:00
Glenn Maynard b5cca118e0 add TWEEN_SMOOTH 2005-08-12 04:08:51 +00:00
Chris Danford 2ca9f32459 add GetDiffuseAlpha 2005-08-03 03:12:35 +00:00
Chris Danford 1f3ed4d3be replace effect delay/period with RampUp/HoldAtHalf/RampDown/HoldAtZero 2005-07-24 03:19:01 +00:00
Chris Danford be596854c4 zoom() should set zoomz too 2005-07-22 19:51:53 +00:00
Glenn Maynard 56fa4fe4b2 Don't create a TempState for every actor. If we use it, we always use it
right away, inside DrawPrimitives().  This cuts down the size of Actor by
about 25%.
2005-07-19 07:54:32 +00:00
Glenn Maynard c05cf4806a yuck. implement copy ctor to copy tweening queue 2005-07-19 06:21:10 +00:00
Glenn Maynard c4495e3900 Don't use deque in Actor; it allocates too much. Store pointers; moving
pointers around is cheap enough.
2005-07-19 05:56:36 +00:00
Glenn Maynard 55d6382c49 add virtual Copy() to Actor 2005-07-18 22:00:19 +00:00
Glenn Maynard 9a6fa1bae8 actor instance tables 2005-07-04 21:45:16 +00:00
Glenn Maynard ff888eaf9e cleanup 2005-06-21 05:23:25 +00:00
Glenn Maynard 4d5643c27f remove include 2005-06-20 04:32:56 +00:00
Glenn Maynard e2cfba413a update registration for various types 2005-06-20 04:23:36 +00:00
Chris Danford 623dc2512f merge PlayCommand2 and PlayCommand so that Actor derivities only have to override one method to get the correct behavior 2005-06-12 00:35:08 +00:00
Chris Danford 98784d3fb5 Split Update into Update and UpdateInternal so that every class doesn't need to early abort in Update when hibernating 2005-06-11 10:32:58 +00:00
Glenn Maynard fcfbfaeddc simplify 2005-06-03 05:04:15 +00:00
Glenn Maynard e7eeb6d89f while I'm in here, remove conversations 2005-05-31 08:13:44 +00:00
Glenn Maynard 83543232e9 remove GetID().
(Having two names for each actor is confusing and overcomplicated.)
2005-05-31 08:09:04 +00:00
Glenn Maynard d59d1c5d4c remove m_sID 2005-05-31 08:03:18 +00:00
Chris Danford dac72665e3 move background file enumerating into BackgroundUtil.*
fix editor background change functionality
2005-05-31 01:17:37 +00:00
Chris Danford d89b0a8dfc add RunCommandsOnLeaves
propagate Reset
2005-05-29 01:00:05 +00:00
Chris Danford 1cc8d4a859 save survival life seconds remaining in HighScore
show SurvivalLifeTime in Ranking
2005-05-08 22:03:41 +00:00
Glenn Maynard 47db6ca9c4 floating-point zbias. For compatibility, 0 is off and 1 is the old "zbias on".
Going beyond 1 is allowed, but the usable/useful range of values is currently
undefined--try to stick to 0..1.
2005-05-06 04:05:02 +00:00
Glenn Maynard 59f6c7848a separately-controllable ZBias 2005-05-06 03:24:41 +00:00
Chris Danford ed5491f57a add Lua method 2005-05-04 09:58:59 +00:00
Glenn Maynard 72327d7e5d add lua helpers
add auxilliary tweening value; this isn't bound to any effect, so it can
safely be used from Lua.
2005-05-03 20:27:50 +00:00
Chris Danford 5907dcafbf add Lua methods 2005-05-03 19:34:47 +00:00
Chris Danford 0ac5e2b008 add Skew for faux italic fonts 2005-05-02 21:43:27 +00:00
Chris Danford f858e3a5b6 send message on beat crossed 2005-05-01 22:59:00 +00:00
Chris Danford 01d59d97ce add base alpha 2005-04-30 07:48:10 +00:00
Glenn Maynard 4ad1b23244 cleanup 2005-04-29 00:07:33 +00:00
Glenn Maynard 4bba3fbaa8 add lights as an effect source 2005-04-28 23:55:47 +00:00
Glenn Maynard 5c43e5b944 lua: GetSecsIntoEffect, GetEffectDelta 2005-04-28 11:24:14 +00:00
Glenn Maynard 8b76b5eafd experimental: allow implementing effects in Lua.
The biggest risk here is performance; we rarely call Lua per-frame.  However,
there are lots of places where we can call Lua while rendering (any time we
call a command), and there's little difference between calling Lua once
every ten frames or once every frame; either way you're counting against the
per-frame time quota to hit vsync.  So, this probably isn't much of a stretch.

Usage is simple:

  OnCommand=luaeffect,Foo
  FooCommand=addx,math.random()*10

Actor commands run during the effect will only apply for that frame.  Don't
call tweening commands ("linear") or anything else that doesn't make sense
in this context; you're modifying m_TempState instead of the tweening queue.
This is hoped to replace some of the more esoteric stuff in the effect code.

For this to be of much use, Lua access to m_fSecsIntoEffect and probably
other stuff is needed.
2005-04-28 10:18:36 +00:00
Glenn Maynard 30f05feedd add per-vertex diffuse color lua bindings 2005-04-24 10:08:55 +00:00