Difference between revisions of "AGI Command Reference - Inventory Item Management Commands"

From AGI Wiki
Jump to navigationJump to search
(Blanked the page)
 
Line 1: Line 1:
[[Tutorials and Guides|Tutorials and Guides Table of Contents]]<br />
 
[[AGI Command Reference|AGI Command Reference Index]]<br />
 
  
<div align="center">
 
Page:
 
[[AGI Command Reference - Arithmetic Commands|1]] |
 
[[AGI Command Reference - Commands to Load and unLoad Resources|2]] |
 
[[AGI Command Reference - Program Control Commands|3]] |
 
[[AGI Command Reference - Object Control Commands|4]] |
 
[[AGI Command Reference - Object Description Commands|5]] |
 
[[AGI Command Reference - Object Motion Control Commands|6]] |
 
[[AGI Command Reference - Inventory Item Management Commands|7]] |
 
[[AGI Command Reference - Picture Resource Management Commands|8]] |
 
[[AGI Command Reference - Sound Resource Management Commands|9]] |
 
[[AGI Command Reference - Text Management Commands|10]] |
 
[[AGI Command Reference - String Management Commands|11]] |
 
[[AGI Command Reference - Initialization Commands|12]] |
 
[[AGI Command Reference - Menu Management Commands|13]] |
 
[[AGI Command Reference - Test Commands|14]] |
 
[[AGI Command Reference - Other Commands|15]] |
 
[[AGI Command Reference - Unknown Commands|16]]
 
</div><br />
 
 
<div align="center"><span style="font-size: 22pt">Inventory Item Management Commands</span><br />
 
''By [[Chris Cromer]]''</div>
 
 
&nbsp;
 
 
OBJECT resources, stored in a separate file OBJECT, are most often used to represent inventory items. An item is a structure which consists of a one-byte field called room and a string of text, the item name. If the room field of an item is 255, the item belongs to the player. Otherwise the item is considered to be in the room with the corresponding ID number.
 
 
Let us consider item management commands.
 
 
== get(n); get.v(n); ==
 
 
<blockquote>Stores 255 in room field of an object n, which means the player owns it.</blockquote>
 
 
== drop(n); ==
 
 
<blockquote>Stores 0 in the room field of object n.</blockquote>
 
 
== put(n, m); put.v(n, m); ==
 
 
<blockquote>Stores the value m (or Var(m)) in the room field of the object n.</blockquote>
 
 
== get.room.v(n, m); ==
 
 
<blockquote>Stores the value of the room field of object Var(n) in Var(m).</blockquote>
 
 
== status(); ==
 
 
<blockquote>The screen is switched to text mode; the top line displays "You are carrying:", then the names of the object with room field equal to 255 are listed. If there are no such objects, the word "nothing" is displayed.<br />
 
<br />
 
If Flag(13) = 1 (allow item selection), a highlight appears which allows the player to select an item name. When Enter is pressed, the selected object number is stored in Var(25). When Esc is pressed, 255 is stored in Var(25).</blockquote>
 
 
&nbsp;
 
 
<div align="center">
 
Page:
 
[[AGI Command Reference - Arithmetic Commands|1]] |
 
[[AGI Command Reference - Commands to Load and unLoad Resources|2]] |
 
[[AGI Command Reference - Program Control Commands|3]] |
 
[[AGI Command Reference - Object Control Commands|4]] |
 
[[AGI Command Reference - Object Description Commands|5]] |
 
[[AGI Command Reference - Object Motion Control Commands|6]] |
 
[[AGI Command Reference - Inventory Item Management Commands|7]] |
 
[[AGI Command Reference - Picture Resource Management Commands|8]] |
 
[[AGI Command Reference - Sound Resource Management Commands|9]] |
 
[[AGI Command Reference - Text Management Commands|10]] |
 
[[AGI Command Reference - String Management Commands|11]] |
 
[[AGI Command Reference - Initialization Commands|12]] |
 
[[AGI Command Reference - Menu Management Commands|13]] |
 
[[AGI Command Reference - Test Commands|14]] |
 
[[AGI Command Reference - Other Commands|15]] |
 
[[AGI Command Reference - Unknown Commands|16]]
 
</div><br />
 
 
[[Tutorials and Guides|Tutorials and Guides Table of Contents]]<br />
 
[[AGI Command Reference|AGI Command Reference Index]]
 
 
<span style="float: left">[[AGI Command Reference - Object Motion Control Commands|&lt; Previous: Object Motion Control Commands]]</span><span style="float: right">[[AGI Command Reference - Picture Resource Management Commands|Next: Picture Resource Management Commands &gt;]]</span>
 
 
&nbsp;
 
 
[[Category:Logic]]
 
[[Category:Commands]]
 
[[Category:References]]
 
[[Category:Tutorials]]
 
[[Category:Inventory]]
 

Latest revision as of 19:53, 22 March 2019