Added tile documentation
This commit is contained in:
13
doc/files/createtilemap.txt
Normal file
13
doc/files/createtilemap.txt
Normal file
@@ -0,0 +1,13 @@
|
||||
#title CreateTileMap [RCBasic Doc]
|
||||
#header Function CreateTileMap(tileset, widthInTiles, heightInTiles)
|
||||
|
||||
Returns a new tile map.
|
||||
|
||||
Parameters
|
||||
#list ul
|
||||
#li tileset - A tileset Id. ( Tilesets are created with CreateTileSet() )
|
||||
#li widthInTiles - The number of tiles wide ( Note: Not the pixel width but number of tiles )
|
||||
#li widthInTiles - The number of tiles high ( Note: Not the pixel height but number of tiles )
|
||||
#/list
|
||||
|
||||
#ref CreateTileSet
|
||||
13
doc/files/createtileset.txt
Normal file
13
doc/files/createtileset.txt
Normal file
@@ -0,0 +1,13 @@
|
||||
#title CreateTileSet [RCBasic Doc]
|
||||
#header Function CreateTileSet(img_id, tile_w, tile_h)
|
||||
|
||||
Return a new Tileset
|
||||
|
||||
Parameters:
|
||||
#list ul
|
||||
#li img_id - A image to use as a tile sheet
|
||||
#li tile_w - The width of each tile
|
||||
#li tile_h - The height of each tile
|
||||
#/list
|
||||
|
||||
#ref CreateTileMap
|
||||
15
doc/files/drawtilemap.txt
Normal file
15
doc/files/drawtilemap.txt
Normal file
@@ -0,0 +1,15 @@
|
||||
#title DrawTileMap [RCBasic Doc]
|
||||
#header Sub DrawTileMap(tilemap, x, y, w, h, offset_x, offset_y)
|
||||
|
||||
Draws a tile map
|
||||
|
||||
Note: Can only be drawn on a regular 2D canvas
|
||||
|
||||
Parameters:
|
||||
#list ul
|
||||
#li tilemap - the tilemap to draw
|
||||
#li x, y - Where to draw the map on the active canvas
|
||||
#li w, h - The size of the tilemap viewport
|
||||
#li offset_x, offset_y - The location in the tilemap to start drawing from
|
||||
#/list
|
||||
|
||||
6
doc/files/filltile.txt
Normal file
6
doc/files/filltile.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title FillTile [RCBasic Doc]
|
||||
#header Sub FillTile(tilemap, tile, x, y, widthInTiles, heightInTiles)
|
||||
|
||||
Fills an area of a tile map with a specified tile
|
||||
|
||||
|
||||
6
doc/files/gettile.txt
Normal file
6
doc/files/gettile.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetTile [RCBasic Doc]
|
||||
#header Function GetTile(tilemap, x, y)
|
||||
|
||||
Returns the tile at a specified location on a tilemap
|
||||
|
||||
Note: (x, y) is a tile position, not an actual coordinate on the map
|
||||
6
doc/files/gettileanimationframe.txt
Normal file
6
doc/files/gettileanimationframe.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetTileAnimationFrame [RCBasic Doc]
|
||||
#header Function GetTileAnimationFrame(tileset, base_tile, anim_frame)
|
||||
|
||||
Returns the tile set at a specified frame in a tiles animation
|
||||
|
||||
#ref SetTileAnimationFrame
|
||||
6
doc/files/gettileanimationlength.txt
Normal file
6
doc/files/gettileanimationlength.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetTileAnimationLength [RCBasic Doc]
|
||||
#header Function GetTileAnimationLength(tileset, base_tile)
|
||||
|
||||
Return the number of frames in a tile's animation
|
||||
|
||||
#ref SetTileAnimationLength
|
||||
6
doc/files/gettileanimationspeed.txt
Normal file
6
doc/files/gettileanimationspeed.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetTileAnimationSpeed [RCBasic Doc]
|
||||
#header Function GetTileAnimationSpeed(tileset, base_tile)
|
||||
|
||||
Returns the fps of a tile's animation
|
||||
|
||||
#ref SetTileAnimationSpeed
|
||||
6
doc/files/gettilemapsize.txt
Normal file
6
doc/files/gettilemapsize.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetTileMapSize [RCBasic Doc]
|
||||
#header Sub GetTileMapSize(tilemap, ByRef widthInTiles, ByRef heightInTiles)
|
||||
|
||||
Gets the size of a tile map
|
||||
|
||||
#ref CreateTileMap SetTileMapSize
|
||||
5
doc/files/settile.txt
Normal file
5
doc/files/settile.txt
Normal file
@@ -0,0 +1,5 @@
|
||||
#title SetTile [RCBasic Doc]
|
||||
#header Sub SetTile(tilemap, tile, x, y)
|
||||
|
||||
Places a tile on a tilemap
|
||||
|
||||
12
doc/files/settileanimationframe.txt
Normal file
12
doc/files/settileanimationframe.txt
Normal file
@@ -0,0 +1,12 @@
|
||||
#title SetTileAnimationFrame [RCBasic Doc]
|
||||
#header Sub SetTileAnimationFrame(tileset, base_tile, anim_frame, tile)
|
||||
|
||||
Sets a frame of animation for a tile
|
||||
|
||||
Parameters:
|
||||
#list ul
|
||||
#li tileset - The tileset that the base_tile is in
|
||||
#li base_tile - The tile with the frame of animation being set
|
||||
#li anim_frame - The specific index in the animation
|
||||
#li tile - The tile to set this frame to
|
||||
#/list
|
||||
6
doc/files/settileanimationlength.txt
Normal file
6
doc/files/settileanimationlength.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title SetTileAnimationLength [RCBasic Doc]
|
||||
#header Sub SetTileAnimationLength(tileset, base_tile, num_frames)
|
||||
|
||||
Sets the number of frames in a tile's animation
|
||||
|
||||
#ref GetTileAnimationLength
|
||||
6
doc/files/settileanimationspeed.txt
Normal file
6
doc/files/settileanimationspeed.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title SetTileAnimationSpeed [RCBasic Doc]
|
||||
#header Sub SetTileAnimationSpeed(tileset, base_tile, speed)
|
||||
|
||||
Sets the speed of a tile's animation
|
||||
|
||||
#ref GetTileAnimationSpeed
|
||||
6
doc/files/settilemapsize.txt
Normal file
6
doc/files/settilemapsize.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title SetTileMapSize [RCBasic Doc]
|
||||
#header Sub SetTileMapSize(tilemap, widthInTiles, heightInTiles)
|
||||
|
||||
Resize a tile map
|
||||
|
||||
#ref CreateTileMap GetTileMapSize
|
||||
Reference in New Issue
Block a user