Skip to content
Browse files

Update src

  • Loading branch information...
1 parent 9927f5e commit bbc0a1313636fe8f2a08e4d914b4ea1beaf067ef blitz-research committed
View
8 src/george/george.monkey
@@ -480,7 +480,7 @@ Class Docs Implements LinkResolver
Method LoadTopic:Void( path:String )
- Local src:=LoadString( "src_docs/"+path+".txt" )
+ Local src:=LoadString( "src_docs/"+path+".txt" ).Replace( "~r","" )
If Not src
Print "Can't load: "+path
Return
@@ -493,14 +493,12 @@ Class Docs Implements LinkResolver
Print "Loading: "+path
- Local src:=LoadString("src_docs/_"+path+".txt")
+ Local src:=LoadString("src_docs/_"+path+".txt").Replace( "~r","" )
If Not src
Print "Can't load: "+path
Return
End
- src=src.Replace("~r","")
-
Local decl:Decl,scope:Decl,decls:=New Stack<Decl>
Local lines:=src.Split("~n"),block:="",buf:=New StringStack
@@ -591,7 +589,7 @@ Function Main()
ChangeDir "../../"
- Local docs:=New Docs(LoadString("page_template.html"))
+ Local docs:=New Docs( LoadString( "page_template.html" ).Replace( "~r","" ) )
docs.MakeDocs
View
2 src/george/src_docs/Drawing with images.txt
@@ -100,7 +100,7 @@ Function Main()
End
</pre>
-The [[List.AddLast|AddLast]] method is called on the list to add an entry each time the user clicks the mouse.
+The [[monkey.list.List.AddLast|AddLast]] method is called on the list to add an entry each time the user clicks the mouse.
The OnRender method draws the list of monkeys by using the enumeration
View
6 src/george/src_docs/First monkey steps.txt
@@ -47,11 +47,11 @@ With our game object defined we extend the basic Update and Render parts of the
The minimum requirements for an animating monkey application are an [[App]] implementing the methods:
-* [[App.OnCreate]] must call [[SetUpdateRate]]
+* [[mojo.app.App.OnCreate|OnCreate]] must call [[SetUpdateRate]]
-* [[App.OnUpdate]] can use mojo input commands
+* [[mojo.app.App.OnUpdate|OnUpdate]] can use mojo input commands
-* [[App.OnRender]] can use mojo drawing commands
+* [[mojo.app.App.OnRender|OnRender]] can use mojo drawing commands
The following draws an animated spiral shape using the [[DrawRect]] command.
View
2 src/george/src_docs/Key codes.txt
@@ -137,4 +137,4 @@ CHAR_RIGHT
CHAR_DOWN
CHAR_INSERT
CHAR_DELETE
-</pre>
+</pre>
View
2 src/george/src_docs/Language reference.txt
@@ -185,7 +185,7 @@ End If Then Else ElseIf EndIf While Wend Repeat Until Forever
For To Step Next Return Module Interface Implements Inline Throw
</pre>
-[[keywords|Language keywords]] are case insensitive - for example, you may use the keyword function, Function or indeed even fUNCTION (not recommended) to declare a function.
+[[Keywords|Language keywords]] are case insensitive - for example, you may use the keyword function, Function or indeed even fUNCTION (not recommended) to declare a function.
The keywords Module, Inline and Array are not currently used by the Monkey language but are reserved for future use.
View
2 src/george/src_docs/Tutorials.txt
@@ -1,7 +1,7 @@
# Tutorials
-Start with [[First Monkey steps]] and [[Drawing with images]], some nice beginner tutorials by Simon Armstrong.
+Start with [[First monkey steps]] and [[Drawing with images]], some nice beginner tutorials by Simon Armstrong.
[Learn Monkey](http://commondatastorage.googleapis.com/monkeycoder.co.nz/blitz-wiki/learnmonkey.pdf) with this friendly beginners guide by James Boyd (pdf).
View
2 src/george/src_docs/_mojo.audio.txt
@@ -47,7 +47,7 @@ path - file path of the sound to load.
## See also
-[[Sound]], [[Resource paths]], [[File format]]
+[[Sound]], [[Resource paths]], [[File formats]]
# Function PlaySound:Int(sound:Sound,channel:Int=0,flags:Int=0)
View
407 src/george/src_docs/_mojo.input.txt
@@ -1,54 +1,13 @@
# Module mojo.input
+# Import mojo.keycodes
+
The input module allows programs to check for user input from a wide variety of devices such keyboards, mice, joysticks and touchsceens.
The input module uses a 'polling' input model, meaning that your program must continually check (or 'poll') the state of input devices. Polling should be performed during the OnUpdate phase of your program.
-
-'# Function SetInputDevice:Int(dev:InputDevice)
-
-
-# Const CHAR_BACKSPACE:Int
-
-
-# Const CHAR_TAB:Int
-
-
-# Const CHAR_ENTER:Int
-
-
-# Const CHAR_ESCAPE:Int
-
-
-# Const CHAR_DELETE:Int
-
-
-# Const CHAR_PAGEUP:Int
-
-
-# Const CHAR_PAGEDOWN:Int
-
-
-# Const CHAR_END:Int
-
-
-# Const CHAR_HOME:Int
-
-
-# Const CHAR_LEFT:Int
-
-
-# Const CHAR_UP:Int
-
-
-# Const CHAR_RIGHT:Int
-
-
-# Const CHAR_DOWN:Int
-
-
-# Const CHAR_INSERT:Int
+Please see the [[Key codes]] page for a full list of keyboard, mouse and joystick constants.
# Function EnableKeyboard:Int()
@@ -141,9 +100,16 @@ End
</pre>
+# Function PeekChar:Int( index:Int )
+
+Returns the character of the character at the specified index in the keyboard character queue. The character is NOT removed from the keyboard character queue.
+
+If there is no character at the specified index, 0 is returned.
+
+
# Function GetChar:Int()
-Returns the character code of the next character in the keyboard character queue, or 0 if no more characters are available.
+Returns the character code of the next character in the keyboard character queue, or 0 if no more characters are available. The character is removed from the keyboard character queue.
The keyboard queue contains characters codes as opposed to the key codes used by KeyDown and KeyUp.
@@ -202,15 +168,6 @@ End
</pre>
-# Const MOUSE_LEFT:Int
-
-
-# Const MOUSE_RIGHT:Int
-
-
-# Const MOUSE_MIDDLE:Int
-
-
# Function MouseX:Float()
Returns the x coordinate of the mouse pointer.
@@ -396,43 +353,7 @@ index - finger index in the range 0 to 31.
[[TouchX]], [[TouchY]], [[TouchDown]], [[MouseHit]]
-# Const JOY_A:Int
-
-
-# Const JOY_B:Int
-
-
-# Const JOY_X:Int
-
-
-# Const JOY_Y:Int
-
-
-# Const JOY_LB:Int
-
-
-# Const JOY_RB:Int
-
-
-# Const JOY_BACK:Int
-
-
-# Const JOY_START:Int
-
-
-# Const JOY_LEFT:Int
-
-
-# Const JOY_UP:Int
-
-
-# Const JOY_RIGHT:Int
-
-
-# Const JOY_DOWN:Int
-
-
-# Function JoyX:Float(index:Int,unit:Int)
+# Function JoyX:Float(index:Int=0,unit:Int=0)
Returns the x, or horizontal, state of a joystick.
@@ -447,7 +368,7 @@ Note: On the XNA target, JoyX, JoyY and JoyZ will all return 0 until a joystick
index - 0 or 1.
-# Function JoyY:Float(index:Int,unit:Int)
+# Function JoyY:Float(index:Int=0,unit:Int=0)
Returns the y, or vertical, state of a joystick.
@@ -462,7 +383,7 @@ Note: On the XNA target, JoyX, JoyY and JoyZ will all return 0 until a joystick
index - 0 or 1.
-# Function JoyZ:Float(index:Int,unit:Int)
+# Function JoyZ:Float(index:Int=0,unit:Int=0)
On Playstation/Xbox style controllers, JoyZ returns the state of the analog shoulder controls.
@@ -477,7 +398,7 @@ Note: On the XNA target, JoyX, JoyY and JoyZ will all return 0 until a joystick
index - 0 or 1.
-# Function JoyDown:Int(button:Int,unit:Int)
+# Function JoyDown:Int(button:Int,unit:Int=0)
Return 1 if the specified joystick button is currently held down, else 0.
@@ -507,7 +428,7 @@ button - joystick button to test.
[[JoyHit]]
-# Function JoyHit:Int(button:Int,unit:Int)
+# Function JoyHit:Int(button:Int,unit:Int=0)
Return the number of times the specified joystick button has been pressed since the last OnUpdate.
@@ -569,299 +490,3 @@ If the device has no accelerometer, 0 is returned.
Accelerometer functionality is currently only available on the android,html5 and ios targets.
-
-# Const KEY_LMB:Int
-
-
-# Const KEY_RMB:Int
-
-
-# Const KEY_MMB:Int
-
-
-# Const KEY_BACKSPACE:Int
-
-
-# Const KEY_TAB:Int
-
-
-# Const KEY_ENTER:Int
-
-
-# Const KEY_SHIFT:Int
-
-
-# Const KEY_CONTROL:Int
-
-
-# Const KEY_ESCAPE:Int
-
-
-# Const KEY_SPACE:Int
-
-
-# Const KEY_PAGEUP:Int
-
-
-# Const KEY_PAGEDOWN:Int
-
-
-# Const KEY_END:Int
-
-
-# Const KEY_HOME:Int
-
-
-# Const KEY_LEFT:Int
-
-
-# Const KEY_UP:Int
-
-
-# Const KEY_RIGHT:Int
-
-
-# Const KEY_DOWN:Int
-
-
-# Const KEY_INSERT:Int
-
-
-# Const KEY_DELETE:Int
-
-
-# Const KEY_0:Int
-
-
-# Const KEY_1:Int
-
-
-# Const KEY_2:Int
-
-
-# Const KEY_3:Int
-
-
-# Const KEY_4:Int
-
-
-# Const KEY_5:Int
-
-
-# Const KEY_6:Int
-
-
-# Const KEY_7:Int
-
-
-# Const KEY_8:Int
-
-
-# Const KEY_9:Int
-
-
-# Const KEY_A:Int
-
-
-# Const KEY_B:Int
-
-
-# Const KEY_C:Int
-
-
-# Const KEY_D:Int
-
-
-# Const KEY_E:Int
-
-
-# Const KEY_F:Int
-
-
-# Const KEY_G:Int
-
-
-# Const KEY_H:Int
-
-
-# Const KEY_I:Int
-
-
-# Const KEY_J:Int
-
-
-# Const KEY_K:Int
-
-
-# Const KEY_L:Int
-
-
-# Const KEY_M:Int
-
-
-# Const KEY_N:Int
-
-
-# Const KEY_O:Int
-
-
-# Const KEY_P:Int
-
-
-# Const KEY_Q:Int
-
-
-# Const KEY_R:Int
-
-
-# Const KEY_S:Int
-
-
-# Const KEY_T:Int
-
-
-# Const KEY_U:Int
-
-
-# Const KEY_V:Int
-
-
-# Const KEY_W:Int
-
-
-# Const KEY_X:Int
-
-
-# Const KEY_Y:Int
-
-
-# Const KEY_Z:Int
-
-
-# Const KEY_F1:Int
-
-
-# Const KEY_F2:Int
-
-
-# Const KEY_F3:Int
-
-
-# Const KEY_F4:Int
-
-
-# Const KEY_F5:Int
-
-
-# Const KEY_F6:Int
-
-
-# Const KEY_F7:Int
-
-
-# Const KEY_F8:Int
-
-
-# Const KEY_F9:Int
-
-
-# Const KEY_F10:Int
-
-
-# Const KEY_F11:Int
-
-
-# Const KEY_F12:Int
-
-
-# Const KEY_SEMICOLON:Int
-
-
-# Const KEY_EQUALS:Int
-
-
-# Const KEY_COMMA:Int
-
-
-# Const KEY_MINUS:Int
-
-
-# Const KEY_PERIOD:Int
-
-
-# Const KEY_SLASH:Int
-
-
-# Const KEY_TILDE:Int
-
-
-# Const KEY_OPENBRACKET:Int
-
-
-# Const KEY_BACKSLASH:Int
-
-
-# Const KEY_CLOSEBRACKET:Int
-
-
-# Const KEY_QUOTES:Int
-
-
-# Const KEY_JOY0:Int
-
-
-# Const KEY_JOY0_A:Int
-
-
-# Const KEY_JOY0_B:Int
-
-
-# Const KEY_JOY0_X:Int
-
-
-# Const KEY_JOY0_Y:Int
-
-
-# Const KEY_JOY0_LB:Int
-
-
-# Const KEY_JOY0_RB:Int
-
-
-# Const KEY_JOY0_BACK:Int
-
-
-# Const KEY_JOY0_START:Int
-
-
-# Const KEY_JOY0_LEFT:Int
-
-
-# Const KEY_JOY0_UP:Int
-
-
-# Const KEY_JOY0_RIGHT:Int
-
-
-# Const KEY_JOY0_DOWN:Int
-
-
-# Const KEY_JOY1_A:Int
-
-
-# Const KEY_JOY2_A:Int
-
-
-# Const KEY_JOY3_A:Int
-
-
-# Const KEY_TOUCH0:Int
-
-
-# Const KEY_BACK:Int
-
-
-# Const KEY_MENU:Int
-
-
-# Const KEY_CLOSE:Int
View
BIN src/rebuildall.exe
Binary file not shown.

0 comments on commit bbc0a13

Please sign in to comment.
Something went wrong with that request. Please try again.