Code: Select all
<?xml version="1.0" encoding="iso-8859-1" ?>
<ZApplication Name="App" Caption="ZGameEditor application" FileVersion="2">
<OnLoaded>
<ZLibrary Comment="Bitmaps">
<Source>
<![CDATA[Bitmap[4] arr_OverworldLocations;
arr_OverworldLocations[1] = bmp_OverLoc01;
arr_OverworldLocations[2] = bmp_OverLoc02;
arr_OverworldLocations[3] = bmp_OverLoc03;]]>
</Source>
</ZLibrary>
</OnLoaded>
<OnUpdate>
<KeyPress Comment="1" Keys="1" RepeatDelay="0.2">
<OnPressed>
<ZExpression Expression="matTex_Material1.Texture = bmp_OverLoc01; //arr_OverworldLocations[1];"/>
</OnPressed>
</KeyPress>
<KeyPress Comment="2" Keys="2" RepeatDelay="0.2">
<OnPressed>
<ZExpression Expression="matTex_Material1.Texture = arr_OverworldLocations[2];"/>
</OnPressed>
</KeyPress>
<KeyPress Comment="3" Keys="3" RepeatDelay="0.2">
<OnPressed>
<ZExpression Expression="matTex_Material1.Texture = arr_OverworldLocations[3];"/>
</OnPressed>
</KeyPress>
</OnUpdate>
<OnRender>
<UseMaterial Material="Material1"/>
<RenderNet>
<RenderVertexExpression>
<![CDATA[//Update each vertex.
//Vertex : current vertex
//TexCoord : current texture coordinate
//Color : current vertex color
Vertex *= 2;]]>
</RenderVertexExpression>
</RenderNet>
</OnRender>
<Content>
<Material Name="Material1">
<Textures>
<MaterialTexture Name="matTex_Material1" Texture="bmp_OverLoc01" TextureWrapMode="2" TexCoords="1"/>
</Textures>
</Material>
<Bitmap Name="bmp_OverLoc01" Width="128" Height="128" Filter="1">
<Producers>
<BitmapCells UsedMetrics="4" RandomSeed="48"/>
</Producers>
</Bitmap>
<Bitmap Name="bmp_OverLoc02" Width="128" Height="128" Filter="1">
<Producers>
<BitmapCells UsedMetrics="4"/>
</Producers>
</Bitmap>
<Bitmap Name="bmp_OverLoc03" Width="128" Height="128" Filter="1">
<Producers>
<BitmapCells UsedMetrics="4" RandomSeed="37"/>
</Producers>
</Bitmap>
</Content>
</ZApplication>