Commit Graph
384 Commits
Author SHA1 Message Date
Glenn Maynard 2fa8986ea6 fix RunCommandsRecursively by implementing it directly
distinguish between Run ("call this function") and Play
("look up the function with this name and call it")
2007-02-20 23:49:13 +00:00
Glenn Maynard 0d693a0ccb remove EffectCommand. Use SetDrawFunction instead; it's cleaner
and can modify any property, not just tweened properties.
2007-02-20 02:06:11 +00:00
Glenn Maynard 94619a7607 fix error handling 2007-02-20 00:33:09 +00:00
Glenn Maynard a5a907af0e bind Draw 2007-02-13 23:59:59 +00:00
Chris Danford f7fc9ceaa5 remove Set/GetHidden, leave *Visible
remove hidden from ActorCommands eventually
2007-02-13 06:32:26 +00:00
Glenn Maynard a9fd52cce0 add TextureUnit param to SetTextureWrapping 2007-02-13 05:56:24 +00:00
Glenn Maynard fcf121feb0 add PlayCommandNoRecurse to fix PlayCommand hack 2007-02-10 05:42:25 +00:00
Glenn Maynard 8ec54555e3 remove obsolete Context 2007-02-03 12:22:03 +00:00
Glenn Maynard fc9d79d7b2 remove old actor parameters; obsoleted by LuaThreadVariable 2007-02-03 11:02:45 +00:00
Glenn Maynard 9bc27fb390 Messages and commands are nearly identical: they both have a name,
they can both have parameters stashed in a table, and they both play
stuff out of the actor command list.  Merge them; now the only
difference between playing and broadcasting a command is that playing
plays recursively on a tree and broadcasting sends to all subscribers.

The distinction between "messages" and "commands" is cosmetic now;
everything is a message.  The only thing special about commands intended
to be received as a broadcast is the "Message" suffix, which subscribes it.
2007-02-03 06:17:02 +00:00
Glenn Maynard 3eb9e96385 more general color table support 2007-01-31 08:45:53 +00:00
Chris Danford ad5604b331 allow #xxxxxx colors in seteffectcolor* 2006-12-07 07:47:20 +00:00
Glenn Maynard 5cc5462722 header cleanup 2006-11-21 05:17:01 +00:00
Glenn Maynard 174f0c16fa update bindings 2006-11-14 04:22:27 +00:00
Glenn Maynard 7e9ec10f3a work on allowing parameters to messages: pass a Message
struct, not just a string
2006-11-13 23:51:24 +00:00
Glenn Maynard a5f5fa0b78 HandleMessage( Message ) 2006-11-13 23:11:25 +00:00
Glenn Maynard e76a9c8965 remove parent parameter. Use self:GetParent(). 2006-10-23 09:14:27 +00:00
Glenn Maynard cd3f228338 covariant Copy() 2006-10-20 00:17:51 +00:00
Glenn Maynard 9279081723 remove old backwards compatibility 2006-10-18 20:19:51 +00:00
Glenn Maynard 1d5e21c778 old comment 2006-10-15 08:29:26 +00:00
Glenn Maynard cea3b4ef5e remove <Command> children. This was only used to generate
command names on the fly.  If you need that, use Lua, eg.:

Actor.Quad {
    [s .. "Command"] = cmd(x,10)
}
2006-10-15 08:28:11 +00:00
Glenn Maynard 3d7f268dae "Optional" attrib unused 2006-10-15 08:25:11 +00:00
Glenn Maynard 2cede5a421 for cases where we take a number as a boolean, accept a boolean
false as false (to transition away from numbers)
2006-10-15 08:17:35 +00:00
Steve Checkoway e87789da7c Rename XToString2 to XToString. 2006-10-15 00:09:18 +00:00
Steve Checkoway 04bff6bc1d Use XToString2. 2006-10-15 00:00:22 +00:00
Glenn Maynard 6ff22acb45 remove hacky Actor::IsType 2006-10-11 23:51:40 +00:00
Glenn Maynard bd9a210628 simplify 2006-10-11 06:56:42 +00:00
Glenn Maynard 9cb1409964 fix comment 2006-10-11 02:39:53 +00:00
Glenn Maynard e11914d4bb LoadFromNode(sDir, pNode) -> LoadFromNode(pNode) 2006-10-09 08:24:10 +00:00
Glenn Maynard f1ca420069 use ActorUtil::GetWhere 2006-10-09 08:08:59 +00:00
Glenn Maynard ce07b22b56 fix up Context handling 2006-10-09 01:15:49 +00:00
Glenn Maynard 3cae60d6fd Currently, expression handling in XML is spotting and inconsistent.
Each actor type needs to evaluate attributes; only a few do.  Strings
are handled with the "@foo()" notation.

Instead, after loading an XML file for loading as an actor,
precompile all XML attributes as Lua expressions.

The primary difference to code is:
 - previously, Attr="string" would act as a string if it was being
   read as one.  Now, specify Attr='"string"'.  Attr="@string" is
   a shorthand.  (note that @strings will not be parsed as Lua
   strings, so can not use Lua escape characters)
 - previously, Attr="@func()" would evaluate func(), and the value
   of the attribute would be the return value of the function.  This
   was only supported for a few attributes.  Now, say Attr="func()",
   and this will work for all fields.
 - Attributes of other types are unchanged, except that all attributes
   may be Lua expressions, eg. Width="SCREEN_WIDTH".
 - Attributes names ending with "Command" are special, like metrics.
   Prefix "%" to disable this.

This brings XML handling in line with metric handling.  (This is an intermediary
step; I have another idea that follows from this that should eliminate the annoying
"'foo'"/"@foo".)
2006-10-09 00:49:30 +00:00
Glenn Maynard 1a89ddfccd pointer to attributes 2006-10-03 00:07:01 +00:00
Glenn Maynard 5d6514a2c1 better debug 2006-10-02 22:54:43 +00:00
Glenn Maynard 9e4da8650f simplify 2006-10-02 22:53:32 +00:00
Glenn Maynard 83defce27b XML update 2006-10-02 22:52:57 +00:00
Glenn Maynard 4b26a19205 cleanup 2006-10-02 21:19:00 +00:00
Glenn Maynard c690fdcfe4 unify registration 2006-09-29 00:01:32 +00:00
Glenn Maynard 205c2329a2 XToString 2006-09-27 20:33:26 +00:00
Glenn Maynard f4975f1f54 simpler Lua boilerplate 2006-09-27 20:30:29 +00:00
Glenn Maynard 3311f1992c CabinetLight_Invalid 2006-09-26 21:23:30 +00:00
Glenn Maynard 02a4b35d51 bound alignment constants 2006-09-26 20:00:27 +00:00
Glenn Maynard 9501cb22e5 standard enum convention 2006-09-26 19:50:53 +00:00
Glenn Maynard cc49e8d56d use bound types 2006-09-26 09:09:38 +00:00
Glenn Maynard f567a0fd28 cleanup arg order 2006-09-26 08:54:54 +00:00
Steve Checkoway 4a545228a9 Simplify. 2006-09-26 05:34:18 +00:00
Glenn Maynard 52ae78a40e self:diffuse({1,1,1,1}) 2006-09-21 22:08:49 +00:00
Glenn Maynard ed81222b34 ActorCommands.h -> Actor.h or ActorUtil.h 2006-09-21 02:48:15 +00:00
Glenn Maynard c2e5a38930 ActorCommands -> ActorUtil::ParseActorCommands 2006-09-21 02:25:10 +00:00
Glenn Maynard 3a57dca6c4 ActorCommands -> ActorUtil::ParseActorCommands 2006-09-21 02:24:22 +00:00