mirror of
https://github.com/moparisthebest/rswiki-book
synced 2024-11-24 01:52:16 -05:00
Create MediaWiki page '317 Construct map region'
This commit is contained in:
parent
b6865d83fa
commit
67aa8a6f15
43
317-Construct-map-region.mediawiki
Normal file
43
317-Construct-map-region.mediawiki
Normal file
@ -0,0 +1,43 @@
|
||||
[[Category Packet]]
|
||||
[[Category Packet 317]]
|
||||
{{packet|name=Construct map region|description=Constructs a new map region from a palette of 8x8 tiles.|opcode=241|type=Variable Short|length=N/A|revision=317}}
|
||||
== Construct Map Region ==
|
||||
|
||||
=== Description ===
|
||||
|
||||
The construct map region packet sends a dynamic map region that is constructed by using groups of 8*8 tiles. It is generally used for instanced areas, such as fight caves, and in later revisions, player owned houses.
|
||||
|
||||
=== Packet Structure ===
|
||||
|
||||
{| border=2
|
||||
! Data type
|
||||
! Description
|
||||
|-
|
||||
| [[Data Types#Standard data types|Short]] [[Data Types#Non Standard Data Types|Special A]]
|
||||
| The region Y coordinate (absolute Y coordinate / 8), plus 6.
|
||||
|-
|
||||
| [[#Bit block|Bit block]]
|
||||
| See below.
|
||||
|-
|
||||
| [[Data Types#Standard data types|Short]]
|
||||
| The region X coordinate (absolute X coordinate / 8), plus 6.
|
||||
|}
|
||||
|
||||
==== Bit block ====
|
||||
|
||||
The bit block actually contains the 'palette' of map regions to make up the new region.
|
||||
|
||||
There is a loop, like this, used to construct it:
|
||||
|
||||
for(int z = 0; z < 4; z++) {
|
||||
for(int x = 0; x < 13; x++) {
|
||||
for(int y = 0; y < 13; y++) {
|
||||
// data for this region
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
The individual format in each iteration of the loop is:
|
||||
|
||||
* '''1 bit''' - set to 0 to indicate to display nothing, 1 to display a region
|
||||
* '''26 bits''' - if the flag above is set to 1 - region x << 14 | region y << 3
|
@ -1,9 +1,9 @@
|
||||
<!-- DO NOT EDIT THIS FILE, CODE AUTOMATICALLY GENERATED BY category.sh -->
|
||||
The following categories contain pages or media.
|
||||
* [[Category Data Type]] (3 members)
|
||||
* [[Category Packet]] (26 members)
|
||||
* [[Category Packet]] (27 members)
|
||||
* [[Category Packet 194]] (1 members)
|
||||
* [[Category Packet 317]] (23 members)
|
||||
* [[Category Packet 317]] (24 members)
|
||||
* [[Category Packet 474]] (1 members)
|
||||
* [[Category Packet {{{revision}}}]] (1 members)
|
||||
* [[Category RS2]] (4 members)
|
||||
|
@ -1,11 +1,12 @@
|
||||
<!-- DO NOT EDIT BELOW THIS LINE, OR CHANGE THIS COMMENT, CODE AUTOMATICALLY GENERATED BY category.sh -->
|
||||
== '''Pages in category "Packet 317"''' ==
|
||||
The following 23 pages are in this category.
|
||||
The following 24 pages are in this category.
|
||||
* [[317 Animation reset]]
|
||||
* [[317 Camera shake]]
|
||||
* [[317 Chat interface]]
|
||||
* [[317 Chat settings]]
|
||||
* [[317 Clear screen]]
|
||||
* [[317 Construct map region]]
|
||||
* [[317 Flash sidebar]]
|
||||
* [[317 Friends list status]]
|
||||
* [[317 Interface color]]
|
||||
|
@ -1,12 +1,13 @@
|
||||
<!-- DO NOT EDIT BELOW THIS LINE, OR CHANGE THIS COMMENT, CODE AUTOMATICALLY GENERATED BY category.sh -->
|
||||
== '''Pages in category "Packet"''' ==
|
||||
The following 26 pages are in this category.
|
||||
The following 27 pages are in this category.
|
||||
* [[194 Protocol]]
|
||||
* [[317 Animation reset]]
|
||||
* [[317 Camera shake]]
|
||||
* [[317 Chat interface]]
|
||||
* [[317 Chat settings]]
|
||||
* [[317 Clear screen]]
|
||||
* [[317 Construct map region]]
|
||||
* [[317 Flash sidebar]]
|
||||
* [[317 Friends list status]]
|
||||
* [[317 Interface color]]
|
||||
|
Loading…
Reference in New Issue
Block a user