summaryrefslogtreecommitdiff
path: root/manuals/sly/REPL.html
diff options
context:
space:
mode:
Diffstat (limited to 'manuals/sly/REPL.html')
-rw-r--r--manuals/sly/REPL.html107
1 files changed, 107 insertions, 0 deletions
diff --git a/manuals/sly/REPL.html b/manuals/sly/REPL.html
new file mode 100644
index 0000000..0811888
--- /dev/null
+++ b/manuals/sly/REPL.html
@@ -0,0 +1,107 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<!-- Copyright (C) 2013, 2014 David Thompson davet@gnu.org
+
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.3
+or any later version published by the Free Software Foundation;
+with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
+A copy of the license is included in the section entitled "GNU
+Free Documentation License".
+
+A copy of the license is also available from the Free Software
+Foundation Web site at http://www.gnu.org/licenses/fdl.html.
+
+
+The document was typeset with
+http://www.texinfo.org/ (GNU Texinfo).
+ -->
+<!-- Created by GNU Texinfo 6.0, http://www.gnu.org/software/texinfo/ -->
+<head>
+<title>Sly: REPL</title>
+
+<meta name="description" content="Sly: REPL">
+<meta name="keywords" content="Sly: REPL">
+<meta name="resource-type" content="document">
+<meta name="distribution" content="global">
+<meta name="Generator" content="makeinfo">
+<meta charset="UTF-8">
+<link href="index.html#Top" rel="start" title="Top">
+<link href="Index.html#Index" rel="index" title="Index">
+<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
+<link href="Utilities.html#Utilities" rel="up" title="Utilities">
+<link href="Live-Reloading.html#Live-Reloading" rel="next" title="Live Reloading">
+<link href="Utilities.html#Utilities" rel="prev" title="Utilities">
+<style type="text/css">
+<!--
+a.summary-letter {text-decoration: none}
+blockquote.indentedblock {margin-right: 0em}
+blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
+blockquote.smallquotation {font-size: smaller}
+div.display {margin-left: 3.2em}
+div.example {margin-left: 3.2em}
+div.lisp {margin-left: 3.2em}
+div.smalldisplay {margin-left: 3.2em}
+div.smallexample {margin-left: 3.2em}
+div.smalllisp {margin-left: 3.2em}
+kbd {font-style: oblique}
+pre.display {font-family: inherit}
+pre.format {font-family: inherit}
+pre.menu-comment {font-family: serif}
+pre.menu-preformatted {font-family: serif}
+pre.smalldisplay {font-family: inherit; font-size: smaller}
+pre.smallexample {font-size: smaller}
+pre.smallformat {font-family: inherit; font-size: smaller}
+pre.smalllisp {font-size: smaller}
+span.nocodebreak {white-space: nowrap}
+span.nolinebreak {white-space: nowrap}
+span.roman {font-family: serif; font-weight: normal}
+span.sansserif {font-family: sans-serif; font-weight: normal}
+ul.no-bullet {list-style: none}
+-->
+</style>
+
+
+</head>
+
+<body lang="en">
+<a name="REPL"></a>
+<div class="header">
+<p>
+Next: <a href="Live-Reloading.html#Live-Reloading" accesskey="n" rel="next">Live Reloading</a>, Up: <a href="Utilities.html#Utilities" accesskey="u" rel="up">Utilities</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Index.html#Index" title="Index" rel="index">Index</a>]</p>
+</div>
+<hr>
+<a name="REPL-1"></a>
+<h4 class="subsection">4.6.1 REPL</h4>
+
+<div class="example">
+<pre class="example">(use-modules (sly utils repl))
+</pre></div>
+
+<p>The Sly REPL is a cooperative REPL server that is integrated into the
+game loop. It is the key to live coding games with Sly. To connect
+to the REPL server, use the <a href="http://www.nongnu.org/geiser/">Geiser</a> extension for GNU Emacs.
+</p>
+<dl>
+<dt><a name="index-start_002dsly_002drepl"></a>Scheme Procedure: <strong>start-sly-repl</strong> <em>[<var>port</var>]</em></dt>
+<dd><p>Start a cooperative REPL server that listens on the given <code>port</code>.
+By default, this port is 37146. Additionally, a process is scheduled
+to poll the REPL server upon every tick of the game loop.
+</p></dd></dl>
+
+<p>The Sly REPL detects when the game loop throws an error and enters a
+special loop for debugging. When in this state, game state will not
+be updated or rendered. When the errors have been fixed, calling the
+<code>resume-game-loop</code> procedure will hand control back to the game
+loop.
+</p>
+<dl>
+<dt><a name="index-resume_002dgame_002dloop"></a>Scheme Procedure: <strong>resume-game-loop</strong></dt>
+<dd><p>Abort from the error handling loop prompt and resume the game loop.
+</p></dd></dl>
+
+
+
+
+</body>
+</html>