Browse Source

Update Pixi info for v1.0.0

master
NGnius (Graham) 4 years ago
parent
commit
c824a99613
1 changed files with 34 additions and 16 deletions
  1. +34
    -16
      site/mods/Pixi/index.html

+ 34
- 16
site/mods/Pixi/index.html View File

@@ -49,10 +49,12 @@
</div>
<div class="content-text" id="pixi-intro-p">
<p><span class="tab"></span>
Pixi adds new commands to Gamecraft's command line to import images, and other stuff, into a game.
Pixi adds two new commands,
<i><b>Pixi</b></i> and <i><b>Pixi2</b></i>,
to Gamecraft's command line to import images, and other stuff, into a game.
Since Pixi places vanilla Gamecraft blocks, imported files should be visible without Pixi installed.
See the background image above this?
That's a picture of Super Mario Bros World 1-1 in Gamecraft using the <i>Pixi2D</i> command for image importing.
That's a picture of Super Mario Bros World 1-1 in Gamecraft using the <i>Pixi</i> command for image importing.
</p>
</div>
<div class="content-header" id="pixi-installation">
@@ -61,7 +63,10 @@
</div>
<div class="content-text" id="pixi-installation-p">
<p><span class="tab"></span>
Before installing Pixi, please patch Gamecraft with
Download and run <a href="https://git.exmods.org/NorbiPeti/GCMM/releases">GCMM</a>, then select and install Pixi from the menu.
</p>
<p><span class="tab"></span>
ADVANCED USERS (old way): Before installing Pixi, please patch Gamecraft with
<a href="https://git.exmods.org/modtainers/GCIPA/releases">GCIPA</a> and install the latest version of
<a href="https://git.exmods.org/modtainers/GamecraftModdingAPI/releases">GamecraftModdingAPI</a>.
@@ -80,9 +85,9 @@
</div>
<div class="content-text" id="pixi-robots-p">
<p>
<i><b>PixiBot "[bot search text]"</b></i> downloads the first search result from Robocraft's community Factory and places it beside you.
<i><b>Pixi "[bot search text]"</b></i> downloads the first search result from Robocraft's community Factory and places it beside you.
<br/><br/>
<i><b>PixiBotFile "[bot filename]"</b></i> converts a bot from <a href="https://github.com/NGnius/rcbup">rcbup</a> to blocks and places it beside you.
<i><b>Pixi2 "robot" "[bot search text]"</b></i> is the more verbose equivalent.
</p>
<p><span class="tab"></span>
In the previous commands, anything between (and including) <i><b>[</b></i> and <i><b>]</b></i> is a command argument that you must replace.
@@ -91,10 +96,10 @@
Changing the scaling will disable conversion for all Robocraft blocks except simple blocks.
</p>
<p><span class="tab"></span>
For example, if you want to import a robot from the CRF called Pixi Art, execute the command <span style="display:inline-block;"><i><b>PixiBot "Pixi Art"</b></i></span> to load the robot into your Gamecraft game world.
For example, if you want to import a robot from the CRF called Pixi Art, execute the command <span style="display:inline-block;"><i><b>Pixi "Pixi Art"</b></i></span> to load the robot into your Gamecraft game world.
</p>
<p><span class="tab"></span>
Under the hood, <i><b>PixiBot</b></i> and <i><b>PixiBotFile</b></i> read the Robocraft robot save format from the <a href="https://factory.robocraftgame.com/">CRF</a> and places the equivalent Gamecraft blocks.
Under the hood, robot importing reads the Robocraft robot save format from the <a href="https://factory.robocraftgame.com/">CRF</a> and places the equivalent Gamecraft blocks.
For blocks which are in Gamecraft and Robocraft (full cubes, prisms, etc.), direct conversion occurs.
If a block does not have a single-block equivalent in Gamecraft, the conversion algorithm will attempt to substitute in an existing blueprint for the block.
Failing that, a text block with the name of the Robocraft block will be placed in its place.
@@ -111,37 +116,50 @@
</div>
<div class="content-text" id="pixi-images-p">
<p>
<i><b>Pixi2D "[image filename]"</b></i> converts an image to blocks and places it beside you.
<i><b>Pixi "[image filename]"</b></i> and equivalently <i><b>Pixi2 "canvas" "[image filename]"</b></i> convert an image to coloured blocks and places it beside you.
High-opacity (>75%) pixels are converted to the block you're holding, medium-opacity (>50%) pixels are converted to glass and low-opacity (<50%) pixels are skipped.
<br/><br/>
<i><b>PixiText "[image filename]"</b></i> converts an image to text and places a text block with that text beside you.
<i><b>Pixi2 "text" "[image filename]"</b></i> converts an image to text and places a text block with that text beside you.
<br/><br/>
<i><b>PixiConsole "[image filename]" "[text block id]"</b></i> converts an image to text and places a console block beside you which changes the specified text block.
<i><b>Pixi2 "console" "[image filename]"</b></i> converts an image to text and places a console block beside you which changes the specified text block.
</p>
<p><span class="tab"></span>
In the previous commands, anything between (and including) <i><b>[</b></i> and <i><b>]</b></i> is a command argument that you must replace.
Do not remove the quotation marks -- those are required for the command to work.
These commands assume that the specified image is in the same folder as Gamecraft.
If your image is in a different folder, please provide the full filepath (eg C:\path\to\image\my_image.png) and put a @ before the quotation marks.
The <i><b>Pixi2D</b></i> command also has a hidden rotation property.
The <i><b>Pixi</b></i> coloured block feature also has a hidden rotation property.
By default, the image will be placed along the xy-plane (rotation 0,0,0).
</p>
<p><span class="tab"></span>
For example, if you want to import an image called <i>pixi_art.png</i> that's stored in Gamecraft's installation directory, execute the command <span style="display:inline-block;"><i><b>Pixi2D "pixi_art.png"</b></i></span> to load the image as blocks.
For example, if you want to import an image called <i>pixi_art.png</i> that's stored in Gamecraft's installation directory, execute the command <span style="display:inline-block;"><i><b>Pixi "pixi_art.png"</b></i></span> to load the image as blocks.
It's important to include the file extension, since Pixi isn't capable of black magic.
</p>
<p><span class="tab"></span>
Image to blocks conversion with <i><b>Pixi2D</b></i> read a file in PNG or JPG format and converts every pixel to the nearest Gamecraft block colour.
Image to blocks conversion with <i><b>Pixi</b></i> or <i><b>Pixi2 "canvas"</b></i> read a file in PNG or JPG format and converts every pixel to the nearest Gamecraft block colour.
Adjacent blocks with the same colour are converted into a single scaled block to reduce the performance impact from larger images.
The combination of colour quantization and optimisation usually results in a 50-75% reduction in block count for an image (compared to 1 block per pixel).
</p>
<p><span class="tab"></span>
Image to text conversion with <i><b>PixiText</b></i> and <i><b>PixiConsole</b></i> converts every pixel from a PNG or JPG image file into a coloured square text character.
Image to text conversion with <i><b>Pixi2 "text"</b></i> and <i><b>Pixi2 "console"</b></i> converts every pixel from a PNG or JPG image file into a coloured square text character.
This process does not optimise for similar adjacent pixels, so images will become more than 10x larger when converted to text.
As a result, images larger than 64x64 pixels are very likely to cause issues with Gamecraft performance and stability.
To ensure that everyone can enjoy your game, and to avoid save corruption, use Pixi's image to text commands sparingly and only for small images.
</p>
</div>
<div class="content-header" id="pixi-commands">
<img src="../../mods/Pixi/pixi-logo.png" width="4%" style="vertical-align: middle;" />
<span style="vertical-align: middle;">Pixi vs Pixi2</span>
</div>
<div class="content-text" id="pixi-commands-p">
<p><span class="tab"></span>
To make your life easier, <i><b>Pixi</b></i> and <i><b>Pixi2</b></i> guess what you want to do so you don't have to memorise niche incantations.
To accomplish this, <i><b>Pixi "[thing]"</b></i> uses the thing to guess what to do.
In the background, Pixi uses sneaky info like the file extension (or lack thereof) to guess correctly.
Similarly, <i><b>Pixi2 "[spell]" "[thing]"</b></i> uses the spell to guess what to do.
Behind the scenes, every importer has a name which Pixi uses to match the spell to a caster.
</p>
</div>
<div class="content-header" id="pixi-dev">
<img src="../../mods/Pixi/pixi-logo.png" width="4%" style="vertical-align: middle;" />
<span style="vertical-align: middle;">Development</span>
@@ -166,10 +184,10 @@
Gamecraft interactions use the <a href="https://git.exmods.org/modtainers/GamecraftModdingAPI">GamecraftModdingAPI</a>.
</p>
<p><span class="tab"></span>
Thanks to <b>TheGreenGoblin</b>, who created the Python app for converting images to coloured square characters which inspired the <i><b>PixiConsole</b></i> and <i><b>PixiText</b></i> commands.
Thanks to <b>TheGreenGoblin</b>, who created the Python app for converting images to coloured square characters which inspired the <i><b>Pixi2 "console"</b></i> and <i><b>Pixi2 "text"</b></i> commands.
</p>
<p><span class="tab"></span>
Thanks to <b>Mr. Rotor</b> for all of the Robocraft blocks used in the <i><b>PixiBot</b></i> and <i><b>PixiBotFile</b></i> commands.
Thanks to <b>Mr. Rotor</b> for all of the Robocraft blocks used in the <i><b>Pixi2 "robot"</b></i> command.
</p>
</div>
<div class="content-header" id="pixi-disclaimer">


Loading…
Cancel
Save