Glenn Maynard
e912b47839
move code around, comment
2005-02-23 03:40:47 +00:00
Glenn Maynard
dfce58ed98
fix commands being parsed multiple times; eg. OnCommand=@'"x," .. foo()' can only run foo() once
2005-02-23 00:22:23 +00:00
Glenn Maynard
fd6a03977d
allow default.xml for backgrounds
2005-02-22 22:13:24 +00:00
Glenn Maynard
350faf7e01
cleanup
2005-02-22 21:44:54 +00:00
Glenn Maynard
b93a347be7
fix crash
2005-02-22 20:18:22 +00:00
Glenn Maynard
61064820b9
SetFromStack
2005-02-22 04:22:24 +00:00
Glenn Maynard
f762300f49
PopStack() calls
2005-02-22 04:20:58 +00:00
Glenn Maynard
61d94e97d8
convert prefs to Preference
2005-02-22 04:00:14 +00:00
Glenn Maynard
6c9cc1b273
disable MemoryCardManager::FlushAndReset
2005-02-22 03:58:22 +00:00
Glenn Maynard
7677c9d88f
GetPreference, SetPreference. (not yet decided if I want to bring Preference itself into Lua)
2005-02-22 03:36:51 +00:00
Glenn Maynard
fda3a8208b
cleanup, pass pn to lua function
2005-02-22 03:34:56 +00:00
Glenn Maynard
2350cc9b77
don't assert if LuaManager::RunScript is called with stuff on the stack
2005-02-22 03:27:06 +00:00
Glenn Maynard
f406e52db3
add LuaReference::Unset; LuaExpression sets nothing by default (so LuaExpressoin is "free" if not actually used)
2005-02-22 03:25:38 +00:00
Glenn Maynard
8a5faeb248
fix copied references being set when the source reference was not
2005-02-22 03:22:56 +00:00
Glenn Maynard
efeabffb8e
allow calling Lua from GameCommand
2005-02-22 01:50:44 +00:00
Glenn Maynard
baf8ef940e
RunScript cleanup, default to 0 return values
2005-02-22 01:21:38 +00:00
Glenn Maynard
1a58675664
cleanup, OnlyDedicatedMenuButtons -> UseDedicatedMenuButtons
2005-02-22 01:20:52 +00:00
Glenn Maynard
7135178e3f
fix SaveTo not being used
2005-02-21 20:18:42 +00:00
Glenn Maynard
b960e51f42
Profile::IsCodeUnlocked
2005-02-21 06:59:50 +00:00
Glenn Maynard
a25eb2443c
lua
2005-02-21 06:51:04 +00:00
Glenn Maynard
1b7d1943e3
lua GetTotalNumSongsPlayed
2005-02-21 06:39:03 +00:00
Glenn Maynard
7e6aaf71cb
fix warning
2005-02-21 06:29:22 +00:00
Glenn Maynard
04ca6e051a
UnlockSystem -> UnlockManager
2005-02-21 06:29:04 +00:00
Glenn Maynard
c691cef8a2
UnlockSystem.cpp -> UnlockManager.cpp
2005-02-21 06:24:47 +00:00
Glenn Maynard
9dbeb4eeef
rename UnlockSystem -> UnlockManager
2005-02-21 06:23:57 +00:00
Glenn Maynard
74d27315d3
s/UnlockSystem.h/UnlockManager.h/
2005-02-21 06:22:46 +00:00
Glenn Maynard
ec75aae7ac
cleanup
2005-02-21 06:16:52 +00:00
Glenn Maynard
afd53b6eb8
rename UnlockSystem to UnlockManager
2005-02-21 06:13:31 +00:00
Glenn Maynard
aef09d0872
quiet down
2005-02-21 03:48:39 +00:00
Glenn Maynard
4b726d2e23
disable whitelisting (will hopefully go away entirely); fix product trimming; better logging
2005-02-21 03:47:47 +00:00
Glenn Maynard
5a75be89ec
fix gcc warnings, maybe other problems
2005-02-21 03:18:08 +00:00
Glenn Maynard
ee54b18b7c
fix gcc warnings
2005-02-21 03:16:15 +00:00
Glenn Maynard
456c45473e
ScreenSelectMaster defaults
2005-02-20 20:39:11 +00:00
Glenn Maynard
df6c246af6
add settext lua method
2005-02-20 07:46:52 +00:00
Glenn Maynard
e8ebcef410
add ConfOption::AddOption
2005-02-20 06:27:50 +00:00
Glenn Maynard
54f469c84e
write extra mappings
...
don't write empty fields
2005-02-20 05:00:56 +00:00
Glenn Maynard
07f941f734
allow more than 3 mappings per GameInput (but don't show them in
...
ScreenMapControllers)
2005-02-20 04:53:57 +00:00
Glenn Maynard
e9a6b578e3
fix (mostly bogus) warnings
2005-02-20 04:49:36 +00:00
Glenn Maynard
f913346852
MoveMap for IPreference*
2005-02-20 04:20:46 +00:00
Glenn Maynard
c1d741a54b
inline
2005-02-20 03:43:32 +00:00
Glenn Maynard
b90a6f1747
inline
2005-02-20 03:09:14 +00:00
Glenn Maynard
11f3514275
simplify
2005-02-20 02:56:51 +00:00
Glenn Maynard
3c49514422
FromString/ToString for strings (no-op)
2005-02-20 02:55:31 +00:00
Glenn Maynard
3c45bca547
fix freeze duration rendering
2005-02-20 01:18:03 +00:00
Glenn Maynard
bb1e676460
fix options menu playing music too early
2005-02-20 00:22:37 +00:00
Glenn Maynard
b8a9d0384a
no, really, don't append a newline here
2005-02-19 10:09:20 +00:00
Glenn Maynard
410679fb44
apply commands to inactive players, too
2005-02-19 09:56:53 +00:00
Glenn Maynard
014a3d65b1
bring back old merged SongsPerPlayOrEvent conf option
2005-02-19 09:16:16 +00:00
Glenn Maynard
23dccd1af2
GzipString, GunzipString
2005-02-19 07:50:00 +00:00
Glenn Maynard
d1fb6a41eb
NotesWriterSM::GetEditFile
2005-02-19 07:48:16 +00:00
Glenn Maynard
3fb7238ac0
SMLoader::LoadEditFromBuffer, SMLoader::LoadEditFromMsd
2005-02-19 07:46:42 +00:00
Glenn Maynard
d9da6cc9fc
MsdFile::ReadFromString
2005-02-19 07:45:12 +00:00
Glenn Maynard
65b82c3e53
accessors
2005-02-19 01:59:31 +00:00
Glenn Maynard
8884936a17
const fix
2005-02-18 03:07:22 +00:00
Glenn Maynard
ffcdaeb515
fix OnCommand not being sent
2005-02-18 00:13:53 +00:00
Glenn Maynard
2270e62eb4
fix expressions (mysterious forces contrived to make this appear to work)
2005-02-17 08:41:13 +00:00
Glenn Maynard
e0853e489d
fix g++ compile
2005-02-17 06:54:17 +00:00
Glenn Maynard
16969b1570
\
2005-02-17 06:30:02 +00:00
Glenn Maynard
1601912c5a
FirstUpdateCommand
2005-02-17 06:16:09 +00:00
Glenn Maynard
8a04a3eeeb
Add ScreenWithMenuElements::FirstUpdateCommand, a Lua expression
...
that gets called on first update. Note the difference between
using ThemeMetric<LuaExpression> and ThemeMetric<ActorCommands>:
with ActorCommands, you get the special, backwards-compatible
parsing; with LuaExpression, only a regular expression is parsed.
You can still only (cleanly) call one function, since "return"
is prepended: if you say "f() g()", it'll try to run "return f() g()".
I tried having a separate type for "expression" and "script", but
it seems confusing to have some metrics parsed as scripts and
some as expressions, allowing multiple functions in only specific
metrics. If you want to do that much, it's cleaner to create
a function and call it, anyway. If you just want to add diagnostics
quickly, you can say "Foo=(function() x() y() z() end)()". (I might
revisit this later.)
2005-02-17 06:13:23 +00:00
Glenn Maynard
01ae30ddd9
Add ThemeManager::GetMetric(LuaExpression)
2005-02-17 06:09:08 +00:00
Glenn Maynard
6f88bf18c0
Cleanup: change RunExpression to a RunScript helper. Never tack on
...
"return "; the caller can do that if it wants. Instead, just act as a helper to
display a generic dialog on error.
2005-02-17 05:46:31 +00:00
Glenn Maynard
d66163ab74
fix error dialog displayed twice: error handling for RunScript is up to the caller
2005-02-17 05:32:50 +00:00
Glenn Maynard
e16b72f5ed
Actor::RunCommands, etc. can take any LuaReference, not just
...
ActorCommands
2005-02-17 05:12:23 +00:00
Glenn Maynard
725a50985f
add constructor
2005-02-17 04:59:54 +00:00
Glenn Maynard
72435f148c
explicit types
2005-02-17 04:55:41 +00:00
Glenn Maynard
d6b13fb134
pronoun
2005-02-17 00:44:26 +00:00
Glenn Maynard
8a62baa1d1
cleanup
2005-02-17 00:41:30 +00:00
Glenn Maynard
45159de835
cleanup
2005-02-17 00:00:04 +00:00
Glenn Maynard
7a7233140b
fix makefile
2005-02-16 22:09:45 +00:00
Glenn Maynard
ce1e6203ee
license
2005-02-16 08:37:08 +00:00
Glenn Maynard
f710506c6c
add TableMetricLookup
2005-02-16 07:50:46 +00:00
Glenn Maynard
97498a4a3e
allow specifying the default
2005-02-16 06:50:37 +00:00
Glenn Maynard
d5cfb74709
split GameState::ApplyGameCommand from GameState::ApplyCmdline;
...
expose to Lua
2005-02-16 06:24:33 +00:00
Glenn Maynard
f4cd02eca8
utils
2005-02-16 06:12:48 +00:00
Glenn Maynard
44b3d97b38
not local
2005-02-16 05:57:40 +00:00
Glenn Maynard
cdf0626ba5
OptionRowTable
2005-02-16 05:56:13 +00:00
Glenn Maynard
ac1d2de3ea
bring back self parameters
2005-02-16 05:26:11 +00:00
Glenn Maynard
1db4aa2600
SetSelections -> SaveSelections, GetSelections -> LoadSelections
2005-02-16 04:47:01 +00:00
Glenn Maynard
073e891589
SetSelections -> SaveSelections, GetSelections -> LoadSelections to avoid
...
confusion with OptionRow
2005-02-16 04:45:47 +00:00
Glenn Maynard
e67d2eee02
zero selections
2005-02-16 04:12:07 +00:00
Glenn Maynard
d470fe11fe
fix assertion failure: SetSelections and GetSelections (currently) take no
...
"self" parameter--you can store the table index in an upvalue if you need
it. (I havn't worked with this enough, yet, to tell which method is better ...)
2005-02-16 03:45:28 +00:00
Glenn Maynard
51d23bb03c
fix comments
2005-02-16 03:40:44 +00:00
Glenn Maynard
6cb8d3fe64
GetMachineProfile
2005-02-16 02:48:50 +00:00
Glenn Maynard
0a0da9809e
allow saving a lua table for each profile
2005-02-16 02:46:43 +00:00
Glenn Maynard
69e57a659e
GetMachineProfile
2005-02-16 02:45:23 +00:00
Glenn Maynard
b8605eebf0
fix warning (atof returns a double, not a float)
2005-02-16 02:42:57 +00:00
Glenn Maynard
69383384bf
add LuaData::Serialize, LuaData::LoadFromString; fix stack overflow
2005-02-16 02:42:05 +00:00
Glenn Maynard
4376c828e5
fix LuaData::BeforeReset
2005-02-16 01:46:29 +00:00
Glenn Maynard
6175a16f24
Add LuaData, a reference type that restores itself over Lua resets. This
...
works only with static data types that can be restored: tables, strings,
numbers, and not functions, userdata, etc.
2005-02-16 00:38:40 +00:00
Glenn Maynard
40fde98efa
add license--just as important for Lua scripts as C++ source
2005-02-16 00:15:36 +00:00
Glenn Maynard
0d8a3723ef
add serialization script
2005-02-16 00:14:17 +00:00
Glenn Maynard
8584cbc0d7
when compiling a script from a file, don't dump the entire contents of the
...
script to the log/dialog
2005-02-15 07:17:49 +00:00
Glenn Maynard
0a0ad8714c
allow LuaManager::RunExpression to return a function
...
show the filename when a full script has an error
use LuaManager::RunExpression in LuaExpression
2005-02-15 02:15:26 +00:00
Glenn Maynard
004d774889
simplify
2005-02-15 02:07:59 +00:00
Glenn Maynard
2103eb0531
bring RunExpression and RunScript closer together
2005-02-15 02:02:08 +00:00
Glenn Maynard
22eee805b9
show the resulting invalid color value when a color metric using a Lua
...
function returns garbage, not the text of the lua call
2005-02-15 01:53:30 +00:00
Glenn Maynard
831e7c1825
remove LuaManager::PushNopFunction(). Just compile an empty function;
...
it'll be tiny, anyway.
2005-02-15 01:49:03 +00:00
Glenn Maynard
db9cd87c34
fix push
2005-02-14 05:57:40 +00:00
Glenn Maynard
0ba4a0b715
test menu
2005-02-14 02:13:55 +00:00