Difference between revisions of "Block (TeaScript)"

From PGE Wiki
Jump to navigation Jump to search
m (Added a stub notice.)
(Actually added stuff to this page.)
Line 1: Line 1:
{{Stub}}
 
 
[[Category:TeaScript.vbs]]
 
[[Category:TeaScript.vbs]]
 
Block is a class in TeaScript.vbs that allows you to read/write values for blocks.
 
Block is a class in TeaScript.vbs that allows you to read/write values for blocks.
 +
 +
To read the value of <code>Block</code> use: <syntaxhighlight lang="vb">
 +
Char(id).name
 +
</syntaxhighlight> <code>id</code> stands for the block ID.
 +
 +
To change the value of <code>Block</code> use: <syntaxhighlight lang="vb">
 +
Char(id).name = value
 +
</syntaxhighlight>
 +
{| class="wikitable" border="0"
 +
!Name
 +
!Description
 +
|-
 +
|<code>X</code>
 +
|The X coordinate of the block.
 +
|-
 +
|<code>Y</code>
 +
|The Y coordinate of the block.
 +
|-
 +
|<code>Xsp</code>
 +
|The X-speed of the block.
 +
|-
 +
|<code>Ysp</code>
 +
|The Y-speed of the block.
 +
|-
 +
|<code>id</code>
 +
|The current block number.
 +
|-
 +
|<code>advset</code>
 +
|The ID of the NPC the block contains.
 +
|}

Revision as of 23:48, 31 August 2019

Block is a class in TeaScript.vbs that allows you to read/write values for blocks.

To read the value of Block use:

Char(id).name

id stands for the block ID. To change the value of Block use:

Char(id).name = value
Name Description
X The X coordinate of the block.
Y The Y coordinate of the block.
Xsp The X-speed of the block.
Ysp The Y-speed of the block.
id The current block number.
advset The ID of the NPC the block contains.