Difference between revisions of "Mods"

From wiki.phychi.com
Jump to: navigation, search
Line 8: Line 8:
  
 
==== Blocks ====
 
==== Blocks ====
All basic block types can be accessed by getBlockByID((number)), blockByID[(number)*100] or blockByName[(string)].
+
===== Access =====
You can get blocks from the [[world]] by calling world.getBlockAt(position x, position y, position z, your call is unimportant? (causing no world loading when true), level (0 by default, greater is bigger))
+
{| class="wikitable" border="1"
You can set blocky by calling world.setBlockAt(x, y, z, block, your call is unimportant?).
+
|-
 
+
! Function
All basic 16² textures are lying on the texture atlas, where you can add your own stuff by calling
+
! Meaning
 +
! Similar
 +
|-
 +
| getBlockByID(id)
 +
| get the basic type of a block
 +
| blockByID[id*100], blockByName[name]
 +
|-
 +
| world.getBlockAt(x, y, z [, unimportant? [, level]])
 +
| get a block from the world, can be a number or an object
 +
| world.getColorAt(x, y, z)
 +
|-
 +
| world.setBlockAt(x, y, z, block [, unimportant?])
 +
| set a block in the world
 +
| world.sba(chunk, chunkchen, x, y, z, block), world.setBlockUnsecure(x, y, z, block)
 +
|}

Revision as of 11:20, 31 December 2016

Mods are modification of the main game including new blocks, new world generation, new ores, new entities, new galaxies, new trading systems, advanced inventory systems etc. They can manipulate every part of the game, so don't use mods from non trusted sources. They may use your idendity at the time you're playing.

API

Current: Alpha

At the moment the ModAPI is just beeing built and can't really be finished before the beta at least is out, so relax, read some books, watch anime, until the really awesome thing of any game is waiting for you! Because of the need of an ModAPI I need to know which features are needed, so I need to write some mods for my game myself, which isn't that easy. Also it should be well documentated and easy to use.

Blocks

Access
Function Meaning Similar
getBlockByID(id) get the basic type of a block blockByID[id*100], blockByName[name]
world.getBlockAt(x, y, z [, unimportant? [, level]]) get a block from the world, can be a number or an object world.getColorAt(x, y, z)
world.setBlockAt(x, y, z, block [, unimportant?]) set a block in the world world.sba(chunk, chunkchen, x, y, z, block), world.setBlockUnsecure(x, y, z, block)