mirror of
https://github.com/ganelson/inform.git
synced 2024-07-08 18:14:21 +03:00
217 lines
9.7 KiB
HTML
217 lines
9.7 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<html>
|
|
<head>
|
|
<title>S/ot2</title>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<meta http-equiv="Content-Language" content="en-gb">
|
|
<link href="inweb.css" rel="stylesheet" rev="stylesheet" type="text/css">
|
|
</head>
|
|
<body>
|
|
|
|
<!--Weave of 'S/ot3' generated by 7-->
|
|
<ul class="crumbs"><li><a href="../webs.html">★</a></li><li><a href="index.html">standard_rules Template Library</a></li><li><b>OutOfWorld Template</b></li></ul><p class="purpose">To implement some of the out of world actions.</p>
|
|
|
|
<ul class="toc"><li><a href="#SP1">§1. Perform Undo</a></li><li><a href="#SP2">§2. Announce Score Rule</a></li><li><a href="#SP3">§3. Switch Score Notification On Rule</a></li><li><a href="#SP4">§4. Standard Report Switching Score Notification On Rule</a></li><li><a href="#SP5">§5. Switch Score Notification Off Rule</a></li><li><a href="#SP6">§6. Standard Report Switching Score Notification Off Rule</a></li><li><a href="#SP7">§7. Prefer Sometimes Abbreviated Room Descriptions Rule</a></li><li><a href="#SP8">§8. Standard Report Prefer Sometimes Abbreviated Room Descriptions Rule</a></li><li><a href="#SP9">§9. Prefer Unabbreviated Room Descriptions Rule</a></li><li><a href="#SP10">§10. Standard Report Prefer Unabbreviated Room Descriptions Rule</a></li><li><a href="#SP11">§11. Prefer Abbreviated Room Descriptions Rule</a></li><li><a href="#SP12">§12. Standard Report Prefer Abbreviated Room Descriptions Rule</a></li><li><a href="#SP13">§13. Announce Pronoun Meanings Rule</a></li></ul><hr class="tocbar">
|
|
|
|
<p class="inwebparagraph"><a id="SP1"></a><b>§1. Perform Undo. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ Perform_Undo;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & PREVENT_UNDO_TCBIT) {</span>
|
|
<span class="plain">IMMEDIATELY_UNDO_RM('A'); new_line; return;</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">if (IterationsOfTurnSequence == 0) { IMMEDIATELY_UNDO_RM('B'); new_line; return; }</span>
|
|
<span class="plain">if (undo_flag == 0) { IMMEDIATELY_UNDO_RM('C'); new_line; return; }</span>
|
|
<span class="plain">if (undo_flag == 1) { IMMEDIATELY_UNDO_RM('D'); new_line; return; }</span>
|
|
<span class="plain">if (VM_Undo() == 0) { IMMEDIATELY_UNDO_RM('F'); new_line; }</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP2"></a><b>§2. Announce Score Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ ANNOUNCE_SCORE_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & USE_SCORING_TCBIT == 0) {</span>
|
|
<span class="plain">ANNOUNCE_SCORE_RM('C'); new_line;</span>
|
|
<span class="plain">} else {</span>
|
|
<span class="plain">ANNOUNCE_SCORE_RM('A'); PrintRank();</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP3"></a><b>§3. Switch Score Notification On Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ SWITCH_SCORE_NOTIFY_ON_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & USE_SCORING_TCBIT == 0) ANNOUNCE_SCORE_R();</span>
|
|
<span class="plain">else notify_mode=1;</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP4"></a><b>§4. Standard Report Switching Score Notification On Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ REP_SWITCH_NOTIFY_ON_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & USE_SCORING_TCBIT) {</span>
|
|
<span class="plain">REP_SWITCH_NOTIFY_ON_RM('A'); new_line;</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP5"></a><b>§5. Switch Score Notification Off Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ SWITCH_SCORE_NOTIFY_OFF_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & USE_SCORING_TCBIT == 0) ANNOUNCE_SCORE_R();</span>
|
|
<span class="plain">else notify_mode=0;</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP6"></a><b>§6. Standard Report Switching Score Notification Off Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ REP_SWITCH_NOTIFY_OFF_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & USE_SCORING_TCBIT) {</span>
|
|
<span class="plain">REP_SWITCH_NOTIFY_OFF_RM('A'); new_line;</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP7"></a><b>§7. Prefer Sometimes Abbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ PREFER_SOMETIMES_ABBREVIATED_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">lookmode=1;</span>
|
|
<span class="plain">]; ! Brief</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP8"></a><b>§8. Standard Report Prefer Sometimes Abbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ REP_PREFER_SOMETIMES_ABBR_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">print (TEXT_TY_Say) Story; REP_PREFER_SOMETIMES_ABBR_RM('A'); new_line;</span>
|
|
<span class="plain">]; ! Brief</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP9"></a><b>§9. Prefer Unabbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ PREFER_UNABBREVIATED_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">lookmode=2;</span>
|
|
<span class="plain">]; ! Verbose</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP10"></a><b>§10. Standard Report Prefer Unabbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ REP_PREFER_UNABBREVIATED_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">print (TEXT_TY_Say) Story; REP_PREFER_UNABBREVIATED_RM('A'); new_line;</span>
|
|
<span class="plain">]; ! Verbose</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP11"></a><b>§11. Prefer Abbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ PREFER_ABBREVIATED_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">lookmode=3;</span>
|
|
<span class="plain">]; ! Superbrief</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP12"></a><b>§12. Standard Report Prefer Abbreviated Room Descriptions Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ REP_PREFER_ABBREVIATED_R;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">print (TEXT_TY_Say) Story; REP_PREFER_ABBREVIATED_RM('A'); new_line;</span>
|
|
<span class="plain">]; ! Superbrief</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<p class="inwebparagraph"><a id="SP13"></a><b>§13. Announce Pronoun Meanings Rule. </b></p>
|
|
|
|
|
|
<pre class="display">
|
|
<span class="plain">[ ANNOUNCE_PRONOUN_MEANINGS_R x y c d;</span>
|
|
<span class="plain">if (actor ~= player) rfalse;</span>
|
|
<span class="plain">ANNOUNCE_PRONOUN_MEANINGS_RM('A');</span>
|
|
|
|
<span class="plain">c = (LanguagePronouns-->0)/3;</span>
|
|
<span class="plain">if (player ~= selfobj) c++;</span>
|
|
|
|
<span class="plain">if (c==0) { ANNOUNCE_PRONOUN_MEANINGS_RM('D'); rtrue; }</span>
|
|
|
|
<span class="plain">for (x = 1, d = 0 : x <= LanguagePronouns-->0: x = x+3) {</span>
|
|
<span class="plain">print "~", (address) LanguagePronouns-->x, "~ ";</span>
|
|
<span class="plain">y = LanguagePronouns-->(x+2);</span>
|
|
<span class="plain">if (y == NULL) ANNOUNCE_PRONOUN_MEANINGS_RM('C');</span>
|
|
<span class="plain">else { ANNOUNCE_PRONOUN_MEANINGS_RM('B'); print (the) y; }</span>
|
|
<span class="plain">d++;</span>
|
|
<span class="plain">if (d < c-1) print ", ";</span>
|
|
<span class="plain">if (d == c-1) {</span>
|
|
<span class="plain">if (TEMPLATE_CONFIGURATION_BITMAP & SERIAL_COMMA_TCBIT) print ",";</span>
|
|
<span class="plain">LIST_WRITER_INTERNAL_RM('C');</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">if (player ~= selfobj) {</span>
|
|
<span class="plain">print "~", (address) ME1__WD, "~ "; ANNOUNCE_PRONOUN_MEANINGS_RM('B');</span>
|
|
<span class="plain">c = player; player = selfobj;</span>
|
|
<span class="plain">print (the) c; player = c;</span>
|
|
<span class="plain">}</span>
|
|
<span class="plain">".";</span>
|
|
<span class="plain">];</span>
|
|
</pre>
|
|
|
|
<p class="inwebparagraph"></p>
|
|
|
|
<hr class="tocbar">
|
|
<ul class="toc"><li><a href="S-ot2.html">Back to 'OrderOfPlay Template'</a></li><li><a href="S-pt.html">Continue with 'Parser Template'</a></li></ul><hr class="tocbar">
|
|
<!--End of weave-->
|
|
</body>
|
|
</html>
|
|
|