fixed crude implementation of speaker.retune

Former-commit-id: eb16dd94b10cc75150508b575c5c0210d18a46cd
Former-commit-id: 84585ddf7e9e839cdfebed086bc671f6b956a462
This commit is contained in:
Song Minjae
2016-09-30 21:01:25 +09:00
parent a25983f513
commit 0859544bd6
12 changed files with 167 additions and 95 deletions

View File

@@ -6,6 +6,7 @@ import org.luaj.vm2.LuaValue
import org.luaj.vm2.lib.TwoArgFunction
import org.luaj.vm2.lib.ZeroArgFunction
import net.torvald.terrarum.virtualcomputer.computer.BaseTerrarumComputer
import org.luaj.vm2.LuaFunction
import org.luaj.vm2.lib.OneArgFunction
/**
@@ -90,7 +91,7 @@ class PcSpeakerDriver(val globals: Globals, host: BaseTerrarumComputer) {
}
}
class Retune(val globals: Globals) : OneArgFunction() {
class Retune(val globals: Globals) : LuaFunction() {
/**
* Examples: C256, A440, A#440, ...
*/
@@ -100,18 +101,24 @@ class PcSpeakerDriver(val globals: Globals, host: BaseTerrarumComputer) {
val baseNote = if (tuneName.contains("#") || tuneName.contains("b")) tuneName.substring(0, 2) else tuneName.substring(0, 1)
val freq = tuneName.replace(Regex("""[^0-9]"""), "").toInt()
// we're assuming C4, C#4, ... A4, A#4, B4
val diffPivot = arrayOf(11, 12, 13, 14, 3, 4, 5, 6, 7, 8, 9, 10) // 2^(12 / n)
// we're assuming the input to be C4, C#4, ... A4, A#4, B4
// diffPivot corsp. to G#4, A4, ...
val diffPivot = arrayOf(-1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10) // 2^(12 / n)
var diff = diffPivot[NOTE_NAMES.indexOf(baseNote)]
if (diff < 0) diff = diffPivot[NOTE_NAMES_ALT.indexOf(baseNote)] // search again
if (diff < 0) throw IllegalArgumentException("Unknown note: $baseNote") // failed to search
val exp = 12.0 / diff
val basefreq = freq * Math.pow(2.0, exp) / 32.0 // converts whatever baseNote to A0
val exp = -diff / 12.0
val basefreq = freq * Math.pow(2.0, exp) / if (diff >= 3) 8.0 else 16.0 // converts whatever baseNote to A0
globals["speaker"]["__basefreq__"] = basefreq
return LuaValue.NONE
}
override fun call(): LuaValue {
globals["speaker"]["__basefreq__"] = LuaValue.valueOf(BASE_FREQ)
return LuaValue.NONE
}
}
class ResetTune(val globals: Globals) : ZeroArgFunction() {

View File

@@ -2,6 +2,8 @@ The Keys library helps you with Input API to get key code by key's names, or ide
Notes on compatibility with ComputerCraft: although this library is ComputerCraft-compliant, but Numpads are \emph{not} supported whatsoever. \textit{Come on, it's not like everyone has or likes numpad on their keyboard.}
\section{Functions}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\

View File

@@ -1,5 +1,7 @@
The Machine API provides means to control the host machine.
\section{Functions}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\

View File

@@ -1,5 +1,7 @@
The OS library provides functions and constants for the system. Most of the functions in the standard Lua are faithfully reconstructed, but there are some functions that behaves differently.
\section{Functions}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\

View File

@@ -1,3 +1,7 @@
\section{Functions}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\

View File

@@ -1,5 +1,7 @@
The Speaker API provides means to control computer's built-in beeper speaker.
\section{Functions}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\
@@ -8,4 +10,18 @@ The Speaker API provides means to control computer's built-in beeper speaker.
\\ \\
speaker.clear() & nil & Clears speaker queue.
\\ \\
speaker.retune(str or nil) & nil & Retunes speaker to specified tuning (e.g. ``A415'', ``C256'', ``A\#440''). If no argument is given, A440 will be used.
\\ \\
speaker.resetTune() & nil & Retunes speaker to A440.
\\ \\
speaker.toFreq(string) & int & Translates input note name to matching frequency based on current speaker tunining.
\end{tabularx}
\section{Constants}
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Name} & \textbf{\large Type} & \textbf{\large Description}
\\ \\
\endhead
speaker.\_\_basefreq\_\_ & number & Frequency of note A-0.
\end{tabularx}

View File

@@ -53,7 +53,8 @@
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {4}Keys}{11}{chapter.4}}
\@writefile{toc}{\contentsline {section}{\numberline {4.1}Accepted Key Names}{11}{section.4.1}}
\@writefile{toc}{\contentsline {section}{\numberline {4.1}Functions}{11}{section.4.1}}
\@writefile{toc}{\contentsline {section}{\numberline {4.2}Accepted Key Names}{11}{section.4.2}}
\gdef \LT@vi {\LT@entry
{2}{104.04007pt}\LT@entry
{2}{45.37001pt}\LT@entry
@@ -66,7 +67,8 @@
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {5}OS}{13}{chapter.5}}
\@writefile{toc}{\contentsline {section}{\numberline {5.1}Date Format String}{13}{section.5.1}}
\@writefile{toc}{\contentsline {section}{\numberline {5.1}Functions}{13}{section.5.1}}
\@writefile{toc}{\contentsline {section}{\numberline {5.2}Date Format String}{13}{section.5.2}}
\gdef \LT@viii {\LT@entry
{2}{136.82pt}\LT@entry
{1}{45.25516pt}\LT@entry
@@ -82,14 +84,21 @@
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {7}Shell}{16}{chapter.7}}
\@writefile{toc}{\contentsline {section}{\numberline {7.1}Functions}{16}{section.7.1}}
\gdef \LT@x {\LT@entry
{2}{165.05502pt}\LT@entry
{1}{45.25516pt}\LT@entry
{1}{124.68982pt}}
\gdef \LT@xi {\LT@entry
{2}{102.20006pt}\LT@entry
{2}{45.37001pt}\LT@entry
{2}{106.29002pt}}
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {8}Speaker}{17}{chapter.8}}
\gdef \LT@xi {\LT@entry
\@writefile{toc}{\contentsline {section}{\numberline {8.1}Functions}{17}{section.8.1}}
\@writefile{toc}{\contentsline {section}{\numberline {8.2}Constants}{17}{section.8.2}}
\gdef \LT@xii {\LT@entry
{2}{139.76003pt}\LT@entry
{1}{45.25516pt}\LT@entry
{1}{149.98482pt}}
@@ -97,7 +106,7 @@
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {9}Terminal}{18}{chapter.9}}
\@writefile{toc}{\contentsline {section}{\numberline {9.1}Functions}{18}{section.9.1}}
\gdef \LT@xii {\LT@entry
\gdef \LT@xiii {\LT@entry
{1}{22.26001pt}\LT@entry
{1}{39.16003pt}\LT@entry
{1}{22.26001pt}\LT@entry
@@ -107,18 +116,18 @@
{1}{22.26001pt}\LT@entry
{1}{58.02002pt}}
\@writefile{toc}{\contentsline {section}{\numberline {9.2}Standard Colours}{20}{section.9.2}}
\gdef \LT@xiii {\LT@entry
\gdef \LT@xiv {\LT@entry
{1}{28.3155pt}\LT@entry
{1}{139.1845pt}\LT@entry
{1}{28.3155pt}\LT@entry
{1}{139.1845pt}}
\@writefile{toc}{\contentsline {section}{\numberline {9.3}Codepage}{21}{section.9.3}}
\@writefile{toc}{\contentsline {section}{\numberline {9.4}Accepted Control Sequences}{21}{section.9.4}}
\gdef \LT@xiv {\LT@entry
\gdef \LT@xv {\LT@entry
{2}{134.13005pt}\LT@entry
{1}{45.25516pt}\LT@entry
{1}{155.61479pt}}
\gdef \LT@xv {\LT@entry
\gdef \LT@xvi {\LT@entry
{2}{135.95003pt}\LT@entry
{2}{36.06001pt}\LT@entry
{1}{162.98996pt}}
@@ -127,29 +136,30 @@
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {10}Lua Globals}{22}{chapter.10}}
\@writefile{toc}{\contentsline {section}{\numberline {10.1}Functions}{22}{section.10.1}}
\@writefile{toc}{\contentsline {section}{\numberline {10.2}Constants}{22}{section.10.2}}
\gdef \LT@xvi {\LT@entry
\gdef \LT@xvii {\LT@entry
{1}{49.09001pt}\LT@entry
{1}{108.52003pt}\LT@entry
{1}{53.81001pt}\LT@entry
{1}{122.25pt}}
\@writefile{toc}{\contentsline {section}{\numberline {10.3}Bell Codes}{24}{section.10.3}}
\@writefile{toc}{\contentsline {subsection}{\numberline {10.3.1}Changes from Generic Lua Environment}{24}{subsection.10.3.1}}
\gdef \LT@xvii {\LT@entry
\gdef \LT@xviii {\LT@entry
{2}{94.0pt}\LT@entry
{1}{45.25516pt}\LT@entry
{1}{195.74484pt}}
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {11}Machine}{25}{chapter.11}}
\@writefile{toc}{\contentsline {section}{\numberline {11.1}Functions}{25}{section.11.1}}
\@writefile{toc}{\contentsline {part}{\partnumberline {II}Compatibility Layers---ComputerCraft}{26}{part.2}}
\gdef \LT@xviii {\LT@entry
\gdef \LT@xix {\LT@entry
{2}{108.45001pt}\LT@entry
{2}{125.76003pt}}
\@writefile{lof}{\addvspace {10pt}}
\@writefile{lot}{\addvspace {10pt}}
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {12}Bit}{27}{chapter.12}}
\@writefile{toc}{\contentsline {section}{\numberline {12.1}Functions}{27}{section.12.1}}
\gdef \LT@xix {\LT@entry
\gdef \LT@xx {\LT@entry
{1}{77.19011pt}\LT@entry
{1}{68.63008pt}\LT@entry
{1}{76.35007pt}\LT@entry
@@ -167,7 +177,7 @@
\@writefile{toc}{\contentsline {chapter}{\chapternumberline {15}Filesystem}{30}{chapter.15}}
\@writefile{toc}{\contentsline {part}{\partnumberline {III}Compatibility Layers---OpenComputers}{31}{part.3}}
\@writefile{toc}{\contentsline {part}{\partnumberline {IV}Peripherals}{32}{part.4}}
\gdef \LT@xx {\LT@entry
\gdef \LT@xxi {\LT@entry
{2}{71.78003pt}\LT@entry
{1}{45.25516pt}\LT@entry
{2}{153.90001pt}}

View File

@@ -1,4 +1,4 @@
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238) (format=lualatex 2015.10.5) 29 SEP 2016 19:27
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238) (format=lualatex 2015.10.5) 30 SEP 2016 20:18
restricted \write18 enabled.
file:line:error style messages enabled.
**romapidoc.tex
@@ -552,7 +552,7 @@ luatexbase-attr: luatexbase.attributes["luaotfload@cursbase"] = 6
luatexbase-attr: luatexbase.attributes["luaotfload@curscurs"] = 7
luatexbase-attr: luatexbase.attributes["luaotfload@cursdone"] = 8
luatexbase-attr: luatexbase.attributes["luaotfload@state"] = 9
luaotfload | main : fontloader loaded in 0.057 seconds
luaotfload | main : fontloader loaded in 0.030 seconds
luatexbase-mcb: inserting 'luaotfload.node_processor'
at position 1 in 'pre_linebreak_filter'
luatexbase-mcb: inserting 'luaotfload.node_processor'
@@ -1460,66 +1460,66 @@ al-though this li-brary is ComputerCraft-
[]
Underfull \hbox (badness 2150) in paragraph at lines 12--12
Underfull \hbox (badness 2150) in paragraph at lines 14--14
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns key name cor-re-sponds to
[]
Overfull \hbox (9.77664pt too wide) in paragraph at lines 72--72
Overfull \hbox (9.77664pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 (\EU2/MyriadPro(0)/m/it/10 zero \EU2/MyriadPro(0)/m
/n/10 to \EU2/MyriadPro(0)/m/it/10 nine\EU2/MyriadPro(0)/m/n/10 )|
[]
Overfull \hbox (1.58002pt too wide) in paragraph at lines 72--72
Overfull \hbox (1.58002pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 backspace|
[]
Overfull \hbox (2.65999pt too wide) in paragraph at lines 72--72
Overfull \hbox (2.65999pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 leftBracket|
[]
Overfull \hbox (9.01001pt too wide) in paragraph at lines 72--72
Overfull \hbox (9.01001pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 rightBracket|
[]
Overfull \hbox (2.23003pt too wide) in paragraph at lines 72--72
Overfull \hbox (2.23003pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 semiColon|
[]
Overfull \hbox (6.18004pt too wide) in paragraph at lines 72--72
Overfull \hbox (6.18004pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 apostrophe|
[]
Overfull \hbox (6.32997pt too wide) in paragraph at lines 72--72
[]|\EU2/MyriadPro(0)/m/n/10 cimcumflex|
[]
Overfull \hbox (5.03001pt too wide) in paragraph at lines 72--72
[]|\EU2/MyriadPro(0)/m/n/10 underscore|
[]
[11
]
Overfull \hbox (4.14001pt too wide) in paragraph at lines 72--72
Overfull \hbox (6.32997pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 cimcumflex|
[]
Overfull \hbox (5.03001pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 underscore|
[]
Overfull \hbox (4.14001pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 pageDown|
[]
Overfull \hbox (15.58pt too wide) in paragraph at lines 72--72
Overfull \hbox (15.58pt too wide) in paragraph at lines 74--74
[]|\EU2/MyriadPro(0)/m/n/10 leftCommand|
[]
) [12] (./api_os.tex
Underfull \hbox (badness 10000) in paragraph at lines 33--33
Underfull \hbox (badness 10000) in paragraph at lines 35--35
[][]|\EU2/MyriadPro(0)/m/n/10 Short month name. (e.g.
[]
@@ -1548,18 +1548,39 @@ Underfull \hbox (badness 2707) in paragraph at lines 20--20
] (./api_speaker.tex
Overfull \hbox (0.686pt too wide) in alignment at lines 11--11
[] [] []
[]
Underfull \hbox (badness 1577) in paragraph at lines 11--11
Underfull \hbox (badness 1577) in paragraph at lines 18--18
[][]|\EU2/MyriadPro(0)/m/n/10 En-queues speaker driv-ing
[]
Package longtable Warning: Column widths have changed
(longtable) in table 8.1 on input line 11.
Underfull \hbox (badness 2384) in paragraph at lines 18--18
[][]|\EU2/MyriadPro(0)/m/n/10 Re-tunes speaker to spec-
[]
Underfull \hbox (badness 10000) in paragraph at lines 18--18
\EU2/MyriadPro(0)/m/n/10 i-fied tun-ing (e.g. ``A415'',
[]
Underfull \hbox (badness 10000) in paragraph at lines 18--18
\EU2/MyriadPro(0)/m/n/10 ``C256'', ``A#440''). If no
[]
Underfull \hbox (badness 5403) in paragraph at lines 18--18
\EU2/MyriadPro(0)/m/n/10 ar-gu-ment is given, A440
[]
Underfull \hbox (badness 10000) in paragraph at lines 18--18
\EU2/MyriadPro(0)/m/n/10 to match-ing fre-quency
[]
Underfull \hbox (badness 1264) in paragraph at lines 18--18
\EU2/MyriadPro(0)/m/n/10 based on cur-rent speaker
[]
) [17
@@ -1612,7 +1633,7 @@ Underfull \hbox (badness 10000) in paragraph at lines 68--68
] [19]
\cpimagew=\skip279
<mda.png, id=310, 4625.28pt x 1798.72pt>
<mda.png, id=341, 4625.28pt x 1798.72pt>
File: mda.png Graphic file (type png)
<use mda.png>
Package pdftex.def Info: mda.png used on input line 90.
@@ -1686,28 +1707,24 @@ luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-Bold.otf" [26
\tf@toc=\write5
\openout5 = romapidoc.toc
Package longtable Warning: Table widths have changed. Rerun LaTeX.
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 182.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 182.
(./romapidoc.aux)
(./romapidoc.aux)
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 182.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 182.
Package rerunfilecheck Info: File `romapidoc.out' has not changed.
(rerunfilecheck) Checksum: E6AA534E637E70890D852319B9FFD1B2;4249.
(rerunfilecheck) Checksum: E2557CFA1EFA2AD5ABDDE2C6217CA0AA;4851.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 182.
)
Here is how much of LuaTeX's memory you used:
27337 strings out of 494693
27351 strings out of 494693
125070,662416 words of node,token memory allocated
794 words of node memory still in use:
3 hlist, 1 vlist, 1 rule, 2 glue, 1 kern, 5 attribute, 141 glue_spec, 5 attri
bute_list, 2 write nodes
avail lists: 2:15095,3:297,4:3729,5:1384,6:6444,7:355,8:30,9:919,10:406
30235 multiletter control sequences out of 65536+600000
avail lists: 1:1,2:15095,3:297,4:3729,5:1384,6:6444,7:355,8:31,9:919,10:406
30242 multiletter control sequences out of 65536+600000
62 fonts using 5300367 bytes
67i,12n,59p,1189b,507s stack positions out of 5000i,500n,10000p,200000b,100000s
LuaTeX warning (dest): name{Hfootnote.2} has been referenced but does not exist,
@@ -1715,10 +1732,10 @@ LuaTeX warning (dest): name{Hfootnote.2} has been referenced but does not exist,
</Library/Fonts/MyriadPro-It.otf></Library/Fonts/MyriadPro-Regular.otf></Library
/Fonts/MyriadPro-Bold.otf>
Output written on romapidoc.pdf (37 pages, 103609 bytes).
Output written on romapidoc.pdf (37 pages, 105016 bytes).
PDF statistics: 429 PDF objects out of 1000 (max. 8388607)
372 compressed objects within 4 object streams
106 named destinations out of 1000 (max. 131072)
321 words of extra memory for PDF output out of 10000 (max. 10000000)
PDF statistics: 461 PDF objects out of 1000 (max. 8388607)
403 compressed objects within 5 object streams
113 named destinations out of 1000 (max. 131072)
369 words of extra memory for PDF output out of 10000 (max. 10000000)

View File

@@ -7,34 +7,40 @@
\BOOKMARK [0][-]{chapter.3}{\376\377\000I\000n\000p\000u\000t}{part.1}% 7
\BOOKMARK [1][-]{section.3.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.3}% 8
\BOOKMARK [0][-]{chapter.4}{\376\377\000K\000e\000y\000s}{part.1}% 9
\BOOKMARK [1][-]{section.4.1}{\376\377\000A\000c\000c\000e\000p\000t\000e\000d\000\040\000K\000e\000y\000\040\000N\000a\000m\000e\000s}{chapter.4}% 10
\BOOKMARK [0][-]{chapter.5}{\376\377\000O\000S}{part.1}% 11
\BOOKMARK [1][-]{section.5.1}{\376\377\000D\000a\000t\000e\000\040\000F\000o\000r\000m\000a\000t\000\040\000S\000t\000r\000i\000n\000g}{chapter.5}% 12
\BOOKMARK [0][-]{chapter.6}{\376\377\000S\000e\000c\000u\000r\000i\000t\000y}{part.1}% 13
\BOOKMARK [1][-]{section.6.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.6}% 14
\BOOKMARK [0][-]{chapter.7}{\376\377\000S\000h\000e\000l\000l}{part.1}% 15
\BOOKMARK [0][-]{chapter.8}{\376\377\000S\000p\000e\000a\000k\000e\000r}{part.1}% 16
\BOOKMARK [0][-]{chapter.9}{\376\377\000T\000e\000r\000m\000i\000n\000a\000l}{part.1}% 17
\BOOKMARK [1][-]{section.9.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.9}% 18
\BOOKMARK [1][-]{section.9.2}{\376\377\000S\000t\000a\000n\000d\000a\000r\000d\000\040\000C\000o\000l\000o\000u\000r\000s}{chapter.9}% 19
\BOOKMARK [1][-]{section.9.3}{\376\377\000C\000o\000d\000e\000p\000a\000g\000e}{chapter.9}% 20
\BOOKMARK [1][-]{section.9.4}{\376\377\000A\000c\000c\000e\000p\000t\000e\000d\000\040\000C\000o\000n\000t\000r\000o\000l\000\040\000S\000e\000q\000u\000e\000n\000c\000e\000s}{chapter.9}% 21
\BOOKMARK [0][-]{chapter.10}{\376\377\000L\000u\000a\000\040\000G\000l\000o\000b\000a\000l\000s}{part.1}% 22
\BOOKMARK [1][-]{section.10.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.10}% 23
\BOOKMARK [1][-]{section.10.2}{\376\377\000C\000o\000n\000s\000t\000a\000n\000t\000s}{chapter.10}% 24
\BOOKMARK [1][-]{section.10.3}{\376\377\000B\000e\000l\000l\000\040\000C\000o\000d\000e\000s}{chapter.10}% 25
\BOOKMARK [0][-]{chapter.11}{\376\377\000M\000a\000c\000h\000i\000n\000e}{part.1}% 26
\BOOKMARK [-1][-]{part.2}{\376\377\000C\000o\000m\000p\000a\000t\000i\000b\000i\000l\000i\000t\000y\000\040\000L\000a\000y\000e\000r\000s\040\024\000C\000o\000m\000p\000u\000t\000e\000r\000C\000r\000a\000f\000t}{}% 27
\BOOKMARK [0][-]{chapter.12}{\376\377\000B\000i\000t}{part.2}% 28
\BOOKMARK [1][-]{section.12.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.12}% 29
\BOOKMARK [0][-]{chapter.13}{\376\377\000C\000o\000l\000o\000r\000s}{part.2}% 30
\BOOKMARK [1][-]{section.13.1}{\376\377\000C\000o\000n\000s\000t\000a\000n\000t\000s}{chapter.13}% 31
\BOOKMARK [1][-]{section.13.2}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.13}% 32
\BOOKMARK [0][-]{chapter.14}{\376\377\000T\000e\000r\000m}{part.2}% 33
\BOOKMARK [0][-]{chapter.15}{\376\377\000F\000i\000l\000e\000s\000y\000s\000t\000e\000m}{part.2}% 34
\BOOKMARK [-1][-]{part.3}{\376\377\000C\000o\000m\000p\000a\000t\000i\000b\000i\000l\000i\000t\000y\000\040\000L\000a\000y\000e\000r\000s\040\024\000O\000p\000e\000n\000C\000o\000m\000p\000u\000t\000e\000r\000s}{}% 35
\BOOKMARK [-1][-]{part.4}{\376\377\000P\000e\000r\000i\000p\000h\000e\000r\000a\000l\000s}{}% 36
\BOOKMARK [0][-]{chapter.16}{\376\377\000L\000i\000n\000e\000\040\000P\000r\000i\000n\000t\000e\000r}{part.4}% 37
\BOOKMARK [1][-]{section.16.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.16}% 38
\BOOKMARK [0][-]{chapter.17}{\376\377\000P\000S\000G}{part.4}% 39
\BOOKMARK [-1][-]{part.5}{\376\377\000R\000e\000f\000e\000r\000e\000n\000c\000e\000s}{}% 40
\BOOKMARK [1][-]{section.4.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.4}% 10
\BOOKMARK [1][-]{section.4.2}{\376\377\000A\000c\000c\000e\000p\000t\000e\000d\000\040\000K\000e\000y\000\040\000N\000a\000m\000e\000s}{chapter.4}% 11
\BOOKMARK [0][-]{chapter.5}{\376\377\000O\000S}{part.1}% 12
\BOOKMARK [1][-]{section.5.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.5}% 13
\BOOKMARK [1][-]{section.5.2}{\376\377\000D\000a\000t\000e\000\040\000F\000o\000r\000m\000a\000t\000\040\000S\000t\000r\000i\000n\000g}{chapter.5}% 14
\BOOKMARK [0][-]{chapter.6}{\376\377\000S\000e\000c\000u\000r\000i\000t\000y}{part.1}% 15
\BOOKMARK [1][-]{section.6.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.6}% 16
\BOOKMARK [0][-]{chapter.7}{\376\377\000S\000h\000e\000l\000l}{part.1}% 17
\BOOKMARK [1][-]{section.7.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.7}% 18
\BOOKMARK [0][-]{chapter.8}{\376\377\000S\000p\000e\000a\000k\000e\000r}{part.1}% 19
\BOOKMARK [1][-]{section.8.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.8}% 20
\BOOKMARK [1][-]{section.8.2}{\376\377\000C\000o\000n\000s\000t\000a\000n\000t\000s}{chapter.8}% 21
\BOOKMARK [0][-]{chapter.9}{\376\377\000T\000e\000r\000m\000i\000n\000a\000l}{part.1}% 22
\BOOKMARK [1][-]{section.9.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.9}% 23
\BOOKMARK [1][-]{section.9.2}{\376\377\000S\000t\000a\000n\000d\000a\000r\000d\000\040\000C\000o\000l\000o\000u\000r\000s}{chapter.9}% 24
\BOOKMARK [1][-]{section.9.3}{\376\377\000C\000o\000d\000e\000p\000a\000g\000e}{chapter.9}% 25
\BOOKMARK [1][-]{section.9.4}{\376\377\000A\000c\000c\000e\000p\000t\000e\000d\000\040\000C\000o\000n\000t\000r\000o\000l\000\040\000S\000e\000q\000u\000e\000n\000c\000e\000s}{chapter.9}% 26
\BOOKMARK [0][-]{chapter.10}{\376\377\000L\000u\000a\000\040\000G\000l\000o\000b\000a\000l\000s}{part.1}% 27
\BOOKMARK [1][-]{section.10.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.10}% 28
\BOOKMARK [1][-]{section.10.2}{\376\377\000C\000o\000n\000s\000t\000a\000n\000t\000s}{chapter.10}% 29
\BOOKMARK [1][-]{section.10.3}{\376\377\000B\000e\000l\000l\000\040\000C\000o\000d\000e\000s}{chapter.10}% 30
\BOOKMARK [0][-]{chapter.11}{\376\377\000M\000a\000c\000h\000i\000n\000e}{part.1}% 31
\BOOKMARK [1][-]{section.11.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.11}% 32
\BOOKMARK [-1][-]{part.2}{\376\377\000C\000o\000m\000p\000a\000t\000i\000b\000i\000l\000i\000t\000y\000\040\000L\000a\000y\000e\000r\000s\040\024\000C\000o\000m\000p\000u\000t\000e\000r\000C\000r\000a\000f\000t}{}% 33
\BOOKMARK [0][-]{chapter.12}{\376\377\000B\000i\000t}{part.2}% 34
\BOOKMARK [1][-]{section.12.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.12}% 35
\BOOKMARK [0][-]{chapter.13}{\376\377\000C\000o\000l\000o\000r\000s}{part.2}% 36
\BOOKMARK [1][-]{section.13.1}{\376\377\000C\000o\000n\000s\000t\000a\000n\000t\000s}{chapter.13}% 37
\BOOKMARK [1][-]{section.13.2}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.13}% 38
\BOOKMARK [0][-]{chapter.14}{\376\377\000T\000e\000r\000m}{part.2}% 39
\BOOKMARK [0][-]{chapter.15}{\376\377\000F\000i\000l\000e\000s\000y\000s\000t\000e\000m}{part.2}% 40
\BOOKMARK [-1][-]{part.3}{\376\377\000C\000o\000m\000p\000a\000t\000i\000b\000i\000l\000i\000t\000y\000\040\000L\000a\000y\000e\000r\000s\040\024\000O\000p\000e\000n\000C\000o\000m\000p\000u\000t\000e\000r\000s}{}% 41
\BOOKMARK [-1][-]{part.4}{\376\377\000P\000e\000r\000i\000p\000h\000e\000r\000a\000l\000s}{}% 42
\BOOKMARK [0][-]{chapter.16}{\376\377\000L\000i\000n\000e\000\040\000P\000r\000i\000n\000t\000e\000r}{part.4}% 43
\BOOKMARK [1][-]{section.16.1}{\376\377\000F\000u\000n\000c\000t\000i\000o\000n\000s}{chapter.16}% 44
\BOOKMARK [0][-]{chapter.17}{\376\377\000P\000S\000G}{part.4}% 45
\BOOKMARK [-1][-]{part.5}{\376\377\000R\000e\000f\000e\000r\000e\000n\000c\000e\000s}{}% 46

Binary file not shown.

View File

@@ -7,13 +7,18 @@
\contentsline {chapter}{\chapternumberline {3}Input}{10}{chapter.3}
\contentsline {section}{\numberline {3.1}Functions}{10}{section.3.1}
\contentsline {chapter}{\chapternumberline {4}Keys}{11}{chapter.4}
\contentsline {section}{\numberline {4.1}Accepted Key Names}{11}{section.4.1}
\contentsline {section}{\numberline {4.1}Functions}{11}{section.4.1}
\contentsline {section}{\numberline {4.2}Accepted Key Names}{11}{section.4.2}
\contentsline {chapter}{\chapternumberline {5}OS}{13}{chapter.5}
\contentsline {section}{\numberline {5.1}Date Format String}{13}{section.5.1}
\contentsline {section}{\numberline {5.1}Functions}{13}{section.5.1}
\contentsline {section}{\numberline {5.2}Date Format String}{13}{section.5.2}
\contentsline {chapter}{\chapternumberline {6}Security}{15}{chapter.6}
\contentsline {section}{\numberline {6.1}Functions}{15}{section.6.1}
\contentsline {chapter}{\chapternumberline {7}Shell}{16}{chapter.7}
\contentsline {section}{\numberline {7.1}Functions}{16}{section.7.1}
\contentsline {chapter}{\chapternumberline {8}Speaker}{17}{chapter.8}
\contentsline {section}{\numberline {8.1}Functions}{17}{section.8.1}
\contentsline {section}{\numberline {8.2}Constants}{17}{section.8.2}
\contentsline {chapter}{\chapternumberline {9}Terminal}{18}{chapter.9}
\contentsline {section}{\numberline {9.1}Functions}{18}{section.9.1}
\contentsline {section}{\numberline {9.2}Standard Colours}{20}{section.9.2}
@@ -25,6 +30,7 @@
\contentsline {section}{\numberline {10.3}Bell Codes}{24}{section.10.3}
\contentsline {subsection}{\numberline {10.3.1}Changes from Generic Lua Environment}{24}{subsection.10.3.1}
\contentsline {chapter}{\chapternumberline {11}Machine}{25}{chapter.11}
\contentsline {section}{\numberline {11.1}Functions}{25}{section.11.1}
\contentsline {part}{\partnumberline {II}Compatibility Layers---ComputerCraft}{26}{part.2}
\contentsline {chapter}{\chapternumberline {12}Bit}{27}{chapter.12}
\contentsline {section}{\numberline {12.1}Functions}{27}{section.12.1}