Re: [Pipmak-Users] Hotspot maps
Status: Alpha
Brought to you by:
cwalther
From: Christian W. <cwa...@gm...> - 2004-09-29 17:54:15
|
Will Meyer wrote: > ok. ok. i'm no longer getting that error after retyping the code. > cutting and pasting the code > introduced weird line end symbols (or at least that's my theory). > unfortunately, with the code in there, pressing the space bar only > result in a message saying "unused > key 32 pressed." > any ideas? Hmm. You are in the node whose node.lua contains the onkeydown handler (press "N" to have Pipmak display the number of the current node), and you did reload (or leave and re-enter) the node after saving the changes to node.lua? Is the keydown handler function called at all when you press a key? You can check by inserting a print statement, like so: onkeydown ( function(key) pipmak.print("Bingo!") if key == string.byte(" ") then ... The whole node.lua file, although it looks like a data file, is actually a Lua script that is executed when the node is loaded. All the configuration keywords like "cubic", "hotspotmap", "onkeydown" are actually Lua functions that manipulate the internal state of the engine. Is the "onkeydown" function that installs the keydown handler called on reloading the node, as it should? To check, use print statements before and after it: pipmak.print("Before!") onkeydown ( ... ) pipmak.print("After!") If these tests don't lead us to a solution, there might be something wrong in Pipmak itself, and I'd have to find and fix that. -Christian |