Jeremy Penner
ab8a0c5860
Proper EDN serialization
2013-05-13 18:04:13 -04:00
Jeremy Penner
ecc4fa4b7e
little cleanups
2013-05-08 20:35:53 -04:00
Jeremy Penner
c60013f21f
edn serialization
2013-05-08 20:35:22 -04:00
Jeremy Penner
4d5e8c2c43
Blobs are stored in gs and are movable with the mouse!
2013-05-04 00:20:13 -04:00
Jeremy Penner
27fa774f7b
rework question API to use arbitrary functions for dispatch
2013-05-04 00:19:46 -04:00
Jeremy Penner
8b3c2d99b0
First cut at simple GUI event dispatch system
2013-05-04 00:19:20 -04:00
Jeremy Penner
b0bf0746c0
add assoc-in-entity / update-in-entity
2013-05-04 00:18:42 -04:00
Jeremy Penner
69c533ceec
fix state machine bugs
2013-05-04 00:18:22 -04:00
Jeremy Penner
5548363a06
Implement the concept of "questions" one can ask of an arbitrary entity (ad-hoc components)
...
Not entirely convinced that this design is the way to go, but am currently without better ideas.
Perhaps each "key" (answerer) could/should provide a dispatch function?
2013-04-30 17:18:50 -04:00
Jeremy Penner
4d0dd8ba8d
Change "value" of stm to be the stm itself, since it couldn't be nil anyway
2013-04-30 17:15:41 -04:00
Jeremy Penner
de29d67036
replace input state machine with much simpler one autogenerated from stm minilanguage
2013-04-05 21:17:15 -04:00
Jeremy Penner
907b45a8ef
Test cases for state machine macro
2013-04-05 21:16:51 -04:00
Jeremy Penner
a239d83dfa
state machine macro bugfixes
2013-04-05 21:10:54 -04:00
Jeremy Penner
4b6519aa13
state machine minilanguage - first cut (buggy)
2013-04-04 23:39:25 -04:00
Jeremy Penner
eb089cacbc
Store event queue in stm; allows enter-state to post fake events
...
allow returning nil from enter-state, on-event
change on-call to return a [stmid value] rather than an arbitrary stm, too much weird shit can go wrong
function to remove a state machine's code
starting to build helper macros for defining state machines
2013-04-02 23:31:18 -04:00
Jeremy Penner
e646c8f7e6
Initial state machine skeleton with testcase
2013-03-31 14:40:11 -04:00
Jeremy Penner
d7c4cac751
bugfix
2013-03-31 14:39:53 -04:00
Jeremy Penner
9d95bc980b
Actual blob shading yaaay
2013-03-27 22:04:40 -04:00
Jeremy Penner
326bd01c7a
simple shader test
2013-03-26 23:56:27 -04:00
Jeremy Penner
35373a45bb
Shader resource support
2013-03-26 23:56:00 -04:00
Jeremy Penner
7119f1ef86
Use latest version of slick
2013-03-26 23:55:39 -04:00
Jeremy Penner
b570ed890d
update gitignore
2013-03-23 23:10:25 -04:00
Jeremy Penner
7033ac5c9b
Create do-sim function which integrates discrete and continuous processing broken up by external events
2013-03-23 23:08:46 -04:00
Jeremy Penner
2ddec2370e
Fix eval for :game to allow modifying state again
2013-03-23 23:07:04 -04:00
Jeremy Penner
0e9de617fa
First cut at a time travel screen (woooooooo!!)
2013-03-19 21:50:11 -04:00
Jeremy Penner
bfe42007f3
Default spec-to-screen conversions
2013-03-19 21:49:38 -04:00
Jeremy Penner
bb183c9869
support more keys
2013-03-19 21:46:55 -04:00
Jeremy Penner
2fd394b6c1
Implement a "nearest time" function for timelines
2013-03-19 21:46:43 -04:00
Jeremy Penner
1b8cb4c148
better stack trace on eval failure (though repl still dies horribly)
2013-03-18 23:31:28 -04:00
Jeremy Penner
bf41a54aec
Screen stack support
...
- rename "game-state" to "screen" (like "title screen", "options screen", etc)
- rename :state to :id
- provide helpers to load a screen given a "spec", deserialize a screen back to a spec, manage a screen stack
- rework test repl helper to allow setting the screen directly, instead of tweaking game state
- have start-game take a spec by default
2013-03-18 23:31:10 -04:00
Jeremy Penner
cc62dfb054
Gamestate API improvements
...
- always include the id as an attribute
- implement query operators that return the whole entity, rather than just the ids
- implement update / delete functions which extract the id from the given entity
2013-03-18 22:33:26 -04:00
Jeremy Penner
1e2de1dd99
Implement new input event model.
...
Input events are now represented as maps containing the complete current state of the user's input devices.
The update method is called with a timeline of all input events since the last call to update.
This neatly solves the "stuck key" problem by making state transitions implicit.
It also solves the problem of different game states (ie. in-game and paused with menu) dealing with input differently.
If part of a game cares about keeping track of all of its input history, and part doesn't, they don't have to fight or know about each other.
2013-03-18 22:15:25 -04:00
Jeremy Penner
eaedaee31a
Some more timeline helpers
2013-03-18 22:06:37 -04:00
Jeremy Penner
7ca348442d
Add update-gs, which always returns the modified gs and is almost always what you want.
2013-03-18 22:02:16 -04:00
Jeremy Penner
dcc5d430e3
Create and provide a timeline of user input events (keyboard / mouse)
...
Make the container accessible from the game object after initialization (mostly for debugging)
Implement some test code (moving a sprite around)
2013-03-14 11:13:44 -05:00
Jeremy Penner
fcc86c782c
Implement timelines (sorted map of timestamps to values)
2013-03-14 11:04:49 -05:00
Jeremy Penner
29409585e9
Simple test "game" with data
2013-03-12 00:19:46 -05:00
Jeremy Penner
d7e0453578
Resource management / caching with optional automatic expiry on file modification
2013-03-12 00:18:01 -05:00
Jeremy Penner
e3d4129d64
refactor clear-and-get-evalqueue into the reusable reset-returning-old!
2013-03-12 00:17:10 -05:00
Jeremy Penner
f3f5d007f9
more id indices and a helper for building them
2013-03-11 15:34:36 -05:00
Jeremy Penner
48fbf954c9
don't bother printing illegible function pointer on eval failure
2013-03-11 15:34:09 -05:00
Jeremy Penner
87fb73f1a3
Fix binding bug in repl where the first value bound to a var when a repl command is evaled is saved in the session bindings forever
2013-03-11 14:45:41 -05:00
Jeremy Penner
339e6f5444
Implement nrepl support, catch exceptions. Hot code reload is now fully operational.
2013-03-10 03:54:09 -05:00
Jeremy Penner
246213c8a2
Initial integration with Slick2d, including hot code reloading
2013-03-09 09:27:42 -06:00
Jeremy Penner
492b5393a1
More idiomatic looping
2013-03-09 09:26:09 -06:00
Jeremy Penner
1118b012f1
Event queue functionality
2013-03-07 23:18:57 -05:00
Jeremy Penner
6b56991689
Add the ability to query arbitrary game states without using with-gs
2013-03-07 23:18:37 -05:00
Jeremy Penner
a32058babd
Initial commit with working gamestate + indexing.
2013-03-05 23:14:20 -05:00