/* DO NOT EDIT THIS FILE - it is machine generated (JCGO_116) */

#ifdef JCGO_SEPARATED
#define JCGO_116
#include "jcgortl.h"
#include "Main.h"
#endif

#ifdef JCGO_116

#ifdef CHKALL_GameModel
#include "jcgobchk.h"
#endif

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__this__L98u34AI( package_GameModel This, jObjectArr
 pieces, jint count )
{
 {
  ;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  JCGO_FIELD_NZACCESS(This, textureTranslucent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, transparent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, key)= (-(jint)1);
  JCGO_FIELD_NZACCESS(This, autocommit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, isolated)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unlit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unpickable)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, projected)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, magic)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, diameter)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= (jint)180;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= (jint)155;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= (jint)95;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= (jint)256;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= (jint)512;
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)32;
  (package_GameModel__merge__L98u34AIZ(
   This, pieces, count, (jboolean)jtrue));
 }
 return This;
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__new__L98u34AI( jObjectArr pieces, jint count )
{
 return package_GameModel__this__L98u34AI(
  (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
  pieces, count);
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__applyRotation__III( package_GameModel This, jint
 yaw, jint roll, jint pitch )
{
 {
  {
   jint v;
   v= 0;
   for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
   {
    if (pitch != 0)
    {
     jint sin;
     jint cos;
     jint x;
     jint jcgo_rcvrI1;
     jint jcgo_rcvrI2;
     sin= JCGO_ARRAY_IACCESS(package_GameModel__sine9, pitch);
     cos= JCGO_ARRAY_IACCESS(package_GameModel__sine9, pitch + (jint)256);
     x= JCGO_SHR_F((jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), v) * sin, jcgo_rcvrI1 + JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), v) * cos), (jint)15);
     (jcgo_rcvrI1= JCGO_SHR_F((jcgo_rcvrI2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), v) * cos, jcgo_rcvrI2 - JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), v) * sin), (jint)15), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), v)= jcgo_rcvrI1);
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
      v)= x;
    }
    if (yaw != 0)
    {
     jint sin;
     jint cos;
     jint y;
     jint jcgo_rcvrI1;
     jint jcgo_rcvrI2;
     sin= JCGO_ARRAY_IACCESS(package_GameModel__sine9, yaw);
     cos= JCGO_ARRAY_IACCESS(package_GameModel__sine9, yaw + (jint)256);
     y= JCGO_SHR_F((jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), v) * cos, jcgo_rcvrI1 - JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v) * sin), (jint)15);
     (jcgo_rcvrI1= JCGO_SHR_F((jcgo_rcvrI2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), v) * sin, jcgo_rcvrI2 + JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v) * cos), (jint)15), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v)= jcgo_rcvrI1);
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
      v)= y;
    }
    if (roll != 0)
    {
     jint sin;
     jint cos;
     jint x;
     jint jcgo_rcvrI1;
     jint jcgo_rcvrI2;
     sin= JCGO_ARRAY_IACCESS(package_GameModel__sine9, roll);
     cos= JCGO_ARRAY_IACCESS(package_GameModel__sine9, roll + (jint)256);
     x= JCGO_SHR_F((jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v) * sin, jcgo_rcvrI1 + JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), v) * cos), (jint)15);
     (jcgo_rcvrI1= JCGO_SHR_F((jcgo_rcvrI2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v) * cos, jcgo_rcvrI2 - JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), v) * sin), (jint)15), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), v)= jcgo_rcvrI1);
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
      v)= x;
    }
   }
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__applyScale__III( package_GameModel This, jint fx,
 jint fy, jint fz )
{
 {
  {
   jint v;
   v= 0;
   for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
   {
    jint jcgo_rcvrI1;
    (jcgo_rcvrI1= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedX), v) * fx, (jint)8), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedX), v)= jcgo_rcvrI1);
    (jcgo_rcvrI1= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedY), v) * fy, (jint)8), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedY), v)= jcgo_rcvrI1);
    (jcgo_rcvrI1= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedZ), v) * fz, (jint)8), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexTransformedZ), v)= jcgo_rcvrI1);
   }
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__applyShear__IIIIII( package_GameModel This, jint
 xy, jint xz, jint yx, jint yz, jint zx, jint zy )
{
 {
  {
   jint idx;
   idx= 0;
   for (; idx < JCGO_FIELD_NZACCESS(This, numVertices); idx++)
   {
    if (xy != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), idx) * xy, (jint)8));
    }
    if (xz != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), idx) * xz, (jint)8));
    }
    if (yx != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), idx) * yx, (jint)8));
    }
    if (yz != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), idx) * yz, (jint)8));
    }
    if (zx != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedZ), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), idx) * zx, (jint)8));
    }
    if (zy != 0)
    {
     jObject jcgo_rcvrL1;
     (jcgo_rcvrL1= (void*)&JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedY), idx), *(jint*)jcgo_rcvrL1+= JCGO_SHR_F(JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexTransformedX), idx) * zy, (jint)8));
    }
   }
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__applyTranslate__III( package_GameModel This, jint
 dx, jint dy, jint dz )
{
 {
  {
   jint v;
   v= 0;
   for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
   {
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     v)+= dx;
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     v)+= dy;
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     v)+= dz;
   }
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__computeBounds__( package_GameModel This )
{
 {
  JCGO_FIELD_NZACCESS(This, x1)= JCGO_FIELD_NZACCESS(This, y1)= JCGO_FIELD_NZACCESS(This,
   z1)= (jint)999999L;
  JCGO_FIELD_NZACCESS(This, diameter)= JCGO_FIELD_NZACCESS(This, x2)=
   JCGO_FIELD_NZACCESS(This, y2)= JCGO_FIELD_NZACCESS(This, z2)= (jint)-999999L;
  {
   jint face;
   face= 0;
   for (; face < JCGO_FIELD_NZACCESS(This, numFaces); face++)
   {
    jintArr vs;
    jint v;
    jint n;
    jint x1;
    jint x2;
    jint y1;
    jint y2;
    jint z1;
    jint z2;
    vs= ((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This, faceVertices),
     face));
    v= JCGO_ARRAY_IACCESS(vs, 0);
    n= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
     face);
    x2= x1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     v);
    y2= y1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     v);
    z2= z1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     v);
    {
     jint i;
     i= 0;
     for (; i < n; i++)
     {
      v= JCGO_ARRAY_NZIACCESS(vs, i);
      if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
       v) < x1)
      {
       x1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
        v);
      }
      else
      {
       if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
        v) > x2)
       {
        x2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
         v);
       }
      }
      if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
       v) < y1)
      {
       y1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
        v);
      }
      else
      {
       if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
        v) > y2)
       {
        y2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
         v);
       }
      }
      if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
       v) < z1)
      {
       z1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
        v);
      }
      else
      {
       if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
        v) > z2)
       {
        z2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
         v);
       }
      }
     }
    }
    if (!JCGO_FIELD_NZACCESS(This, isolated))
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundLeft), face)=
      x1;
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundRight),
      face)= x2;
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundBottom),
      face)= y1;
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundTop), face)=
      y2;
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundNear), face)=
      z1;
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceBoundFar), face)=
      z2;
    }
    if (x2 - x1 > JCGO_FIELD_NZACCESS(This, diameter))
    {
     JCGO_FIELD_NZACCESS(This, diameter)= x2 - x1;
    }
    if (y2 - y1 > JCGO_FIELD_NZACCESS(This, diameter))
    {
     JCGO_FIELD_NZACCESS(This, diameter)= y2 - y1;
    }
    if (z2 - z1 > JCGO_FIELD_NZACCESS(This, diameter))
    {
     JCGO_FIELD_NZACCESS(This, diameter)= z2 - z1;
    }
    if (x1 < JCGO_FIELD_NZACCESS(This, x1))
    {
     JCGO_FIELD_NZACCESS(This, x1)= x1;
    }
    if (x2 > JCGO_FIELD_NZACCESS(This, x2))
    {
     JCGO_FIELD_NZACCESS(This, x2)= x2;
    }
    if (y1 < JCGO_FIELD_NZACCESS(This, y1))
    {
     JCGO_FIELD_NZACCESS(This, y1)= y1;
    }
    if (y2 > JCGO_FIELD_NZACCESS(This, y2))
    {
     JCGO_FIELD_NZACCESS(This, y2)= y2;
    }
    if (z1 < JCGO_FIELD_NZACCESS(This, z1))
    {
     JCGO_FIELD_NZACCESS(This, z1)= z1;
    }
    if (z2 > JCGO_FIELD_NZACCESS(This, z2))
    {
     JCGO_FIELD_NZACCESS(This, z2)= z2;
    }
   }
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__relight__( package_GameModel This )
{
 {
  if (JCGO_FIELD_NZACCESS(This, unlit) && JCGO_FIELD_NZACCESS(This,
   isolated))
  {
   return;
  }
  {
   jint face;
   face= 0;
   for (; face < JCGO_FIELD_NZACCESS(This, numFaces); face++)
   {
    jintArr verts;
    jint aX;
    jint aY;
    jint aZ;
    jint bX;
    jint bY;
    jint bZ;
    jint cX;
    jint cY;
    jint cZ;
    jint normX;
    jint normY;
    jint normZ;
    jint normMag;
    jint jcgo_rcvrI1;
    verts= ((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This, faceVertices),
     face));
    aX= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     JCGO_ARRAY_IACCESS(verts, 0));
    aY= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     JCGO_ARRAY_NZIACCESS(verts, 0));
    aZ= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     JCGO_ARRAY_NZIACCESS(verts, 0));
    bX= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     JCGO_ARRAY_NZIACCESS(verts, (jint)1)) - aX;
    bY= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     JCGO_ARRAY_NZIACCESS(verts, (jint)1)) - aY;
    bZ= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     JCGO_ARRAY_NZIACCESS(verts, (jint)1)) - aZ;
    cX= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     JCGO_ARRAY_NZIACCESS(verts, (jint)2)) - aX;
    cY= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     JCGO_ARRAY_NZIACCESS(verts, (jint)2)) - aY;
    cZ= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     JCGO_ARRAY_NZIACCESS(verts, (jint)2)) - aZ;
    normX= bY * cZ - cY * bZ;
    normY= bZ * cX - cZ * bX;
    for (normZ= bX * cY - cX * bY; normX > (jint)8192 || normY > (jint)8192 ||
     normZ > (jint)8192 || normX < (-(jint)8192) || normY < (-(jint)8192) ||
     normZ < (-(jint)8192); normZ= JCGO_SHR_F(normZ, (jint)1))
    {
     normX= JCGO_SHR_F(normX, (jint)1);
     normY= JCGO_SHR_F(normY, (jint)1);
    }
    normMag= JCGO_JDOUBLE_TOJINT(((jdouble)256.0 * (java_lang_Math__sqrt__D(
     (jdouble)(normX * normX + normY * normY + normZ * normZ)))));
    if (normMag <= 0)
    {
     normMag= (jint)1;
    }
    (jcgo_rcvrI1= jcgo_div((normX * (jint)65536L), normMag), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     faceNormalX), face)= jcgo_rcvrI1);
    (jcgo_rcvrI1= jcgo_div((normY * (jint)65536L), normMag), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     faceNormalY), face)= jcgo_rcvrI1);
    (jcgo_rcvrI1= jcgo_div((normZ * (jint)65535L), normMag), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     faceNormalZ), face)= jcgo_rcvrI1);
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, normalScale), face)=
     (-(jint)1);
   }
  }
  (package_GameModel__light__(
   This));
 }
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__this__L98u34AIZZZZ( package_GameModel This, jObjectArr
 pieces, jint count, jboolean autocommit, jboolean isolated, jboolean
 unlit, jboolean unpickable )
{
 {
  ;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  JCGO_FIELD_NZACCESS(This, textureTranslucent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, transparent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, key)= (-(jint)1);
  JCGO_FIELD_NZACCESS(This, projected)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, magic)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, diameter)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= (jint)180;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= (jint)155;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= (jint)95;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= (jint)256;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= (jint)512;
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)32;
  JCGO_FIELD_NZACCESS(This, autocommit)= (jboolean)autocommit;
  JCGO_FIELD_NZACCESS(This, isolated)= (jboolean)isolated;
  JCGO_FIELD_NZACCESS(This, unlit)= (jboolean)unlit;
  JCGO_FIELD_NZACCESS(This, unpickable)= (jboolean)unpickable;
  (package_GameModel__merge__L98u34AIZ(
   This, pieces, count, (jboolean)jfalse));
 }
 return This;
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__new__L98u34AIZZZZ( jObjectArr pieces, jint count,
 jboolean autocommit, jboolean isolated, jboolean unlit, jboolean unpickable
 )
{
 return package_GameModel__this__L98u34AIZZZZ(
  (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
  pieces, count, autocommit, isolated, unlit, unpickable);
}

JCGO_NOSEP_STATIC package_GameModel CFASTCALL
package_GameModel__this__IIZZZZZ( package_GameModel This, jint numVertices,
 jint numFaces, jboolean autocommit, jboolean isolated, jboolean unlit,
 jboolean unpickable, jboolean projected )
{
 {
  ;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  JCGO_FIELD_NZACCESS(This, textureTranslucent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, transparent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, key)= (-(jint)1);
  JCGO_FIELD_NZACCESS(This, magic)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, diameter)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= (jint)180;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= (jint)155;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= (jint)95;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= (jint)256;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= (jint)512;
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)32;
  JCGO_FIELD_NZACCESS(This, autocommit)= (jboolean)autocommit;
  JCGO_FIELD_NZACCESS(This, isolated)= (jboolean)isolated;
  JCGO_FIELD_NZACCESS(This, unlit)= (jboolean)unlit;
  JCGO_FIELD_NZACCESS(This, unpickable)= (jboolean)unpickable;
  JCGO_FIELD_NZACCESS(This, projected)= (jboolean)projected;
  (package_GameModel__allocate__II(
   This, numVertices, numFaces));
 }
 return This;
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__new__IIZZZZZ( jint numVertices, jint numFaces,
 jboolean autocommit, jboolean isolated, jboolean unlit, jboolean unpickable,
 jboolean projected )
{
 JCGO_CLINIT_TRIG(package_GameModel__class);
 return package_GameModel__this__IIZZZZZ(
  (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
  numVertices, numFaces, autocommit, isolated, unlit, unpickable, projected);
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__copyLighting__L98u34IAII( package_GameModel This,
 package_GameModel model, jintArr srcVs, jint nV, jint inF )
{
 {
  jintArr dstVs;
  jint outF;
  jObject jcgo_rcvrL1;
  jint jcgo_rcvrI1;
  jint jcgo_rcvrI2;
  dstVs= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0, nV);
  {
   jint inV;
   inV= 0;
   for (; inV < nV; inV++)
   {
    jint outV;
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    jint jcgo_rcvrI3;
    jint jcgo_rcvrI4;
    jbyte jcgo_rcvrB1;
    outV= (jcgo_rcvrL1= (jObject)dstVs, jcgo_rcvrI1= inV, jcgo_rcvrI2=
     (jcgo_rcvrI3= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX),
     JCGO_ARRAY_IACCESS(srcVs, inV)), jcgo_rcvrI4= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexY), JCGO_ARRAY_IACCESS(srcVs, inV)), JCGO_CALL_FINALF(model)
     package_GameModel__vertexAt__III(
     model, jcgo_rcvrI3, jcgo_rcvrI4, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
     vertexZ), JCGO_ARRAY_IACCESS(srcVs, inV)))), JCGO_ARRAY_NZIACCESS((jintArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= jcgo_rcvrI2);
    (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexIntensity),
     JCGO_ARRAY_NZIACCESS(srcVs, inV)), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(model,
     vertexIntensity), outV)= jcgo_rcvrI1);
    (jcgo_rcvrB1= JCGO_ARRAY_BACCESS(JCGO_FIELD_NZACCESS(This, vertexAmbience),
     JCGO_ARRAY_NZIACCESS(srcVs, inV)), JCGO_ARRAY_BACCESS(JCGO_FIELD_NZACCESS(model,
     vertexAmbience), outV)= jcgo_rcvrB1);
   }
  }
  outF= (jcgo_rcvrI1= nV, jcgo_rcvrL1= (jObject)dstVs, jcgo_rcvrI2=
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillFront), inF),
   JCGO_CALL_FINALF(model) package_GameModel__createFace__IIAII(
   model, (jintArr)jcgo_rcvrL1, jcgo_rcvrI1, jcgo_rcvrI2, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
   faceFillBack), inF)));
  if (!JCGO_FIELD_NZACCESS(model, unpickable) && !JCGO_FIELD_NZACCESS(This,
   unpickable))
  {
   jint jcgo_rcvrI1;
   (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceTag),
    inF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(model, faceTag), outF)=
    jcgo_rcvrI1);
  }
  (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity),
   inF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(model, faceIntensity),
   outF)= jcgo_rcvrI1);
  (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, normalScale),
   inF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(model, normalScale),
   outF)= jcgo_rcvrI1);
  (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, normalMagnitude),
   inF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(model, normalMagnitude),
   outF)= jcgo_rcvrI1);
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__projectionPrepare__( package_GameModel This )
{
 {
  JCGO_FIELD_NZACCESS(This, projectVertexX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
  JCGO_FIELD_NZACCESS(This, projectVertexY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
  JCGO_FIELD_NZACCESS(This, projectVertexZ)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
  JCGO_FIELD_NZACCESS(This, vertexViewX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
  JCGO_FIELD_NZACCESS(This, vertexViewY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
 }
}

JCGO_NOSEP_STATIC package_GameModel CFASTCALL
package_GameModel__this__II( package_GameModel This, jint numVertices,
 jint numFaces )
{
 {
  jint jcgo_rcvrI1;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  JCGO_FIELD_NZACCESS(This, textureTranslucent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, transparent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, key)= (-(jint)1);
  JCGO_FIELD_NZACCESS(This, autocommit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, isolated)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unlit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unpickable)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, projected)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, magic)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, diameter)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= (jint)180;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= (jint)155;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= (jint)95;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= (jint)256;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= (jint)512;
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)32;
  (package_GameModel__allocate__II(
   This, numVertices, numFaces));
  JCGO_FIELD_NZACCESS(This, faceTransStateThing)= (jcgo_rcvrI1= numFaces,
   jcgo_new4DArray(JCGO_CORECLASS_FOR(OBJT_jint), 2, 0, jcgo_rcvrI1,
   (jint)1, 0, 0));
  {
   jint v;
   v= 0;
   for (; v < numFaces; v++)
   {
    JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
     faceTransStateThing), v)), 0)= v;
   }
  }
 }
 return This;
}

JCGO_NOSEP_FRWINL package_GameModel CFASTCALL
package_GameModel__new__II( jint numVertices, jint numFaces )
{
 JCGO_CLINIT_TRIG(package_GameModel__class);
 return package_GameModel__this__II(
  (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
  numVertices, numFaces);
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__this__BAIZ( package_GameModel This, jbyteArr data,
 jint offset, jboolean unused )
{
 {
  jint j;
  jint k;
  jint jcgo_rcvrI1;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  JCGO_FIELD_NZACCESS(This, textureTranslucent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, transparent)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, key)= (-(jint)1);
  JCGO_FIELD_NZACCESS(This, autocommit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, isolated)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unlit)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, unpickable)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, projected)= (jboolean)jfalse;
  JCGO_FIELD_NZACCESS(This, magic)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, diameter)= package_World__colourTransparent;
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= (jint)180;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= (jint)155;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= (jint)95;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= (jint)256;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= (jint)512;
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)32;
  j= (package_Utility__getUnsignedShort__BAI(
   data, offset));
  offset+= (jint)2;
  k= (package_Utility__getUnsignedShort__BAI(
   data, offset));
  offset+= (jint)2;
  (package_GameModel__allocate__II(
   This, j, k));
  JCGO_FIELD_NZACCESS(This, faceTransStateThing)= (jcgo_rcvrI1= k,
   jcgo_new4DArray(JCGO_CORECLASS_FOR(OBJT_jint), 2, 0, jcgo_rcvrI1,
   (jint)1, 0, 0));
  {
   jint l;
   l= 0;
   for (; l < j; l++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, vertexX), jcgo_rcvrI1=
     l, jcgo_rcvrI2= (package_Utility__getSignedShort__BAI(
     data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
    offset+= (jint)2;
   }
  }
  {
   jint i1;
   i1= 0;
   for (; i1 < j; i1++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, vertexY), jcgo_rcvrI1=
     i1, jcgo_rcvrI2= (package_Utility__getSignedShort__BAI(
     data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
    offset+= (jint)2;
   }
  }
  {
   jint j1;
   j1= 0;
   for (; j1 < j; j1++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, vertexZ), jcgo_rcvrI1=
     j1, jcgo_rcvrI2= (package_Utility__getSignedShort__BAI(
     data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
    offset+= (jint)2;
   }
  }
  JCGO_FIELD_NZACCESS(This, numVertices)= j;
  {
   jint k1;
   k1= 0;
   for (; k1 < k; k1++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, faceNumVertices),
     jcgo_rcvrI1= k1, jcgo_rcvrI2= (jint)((unsigned char)(JCGO_ARRAY_NZBACCESS(data,
     offset++))), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
   }
  }
  {
   jint l1;
   l1= 0;
   for (; l1 < k; l1++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, faceFillFront),
     jcgo_rcvrI1= l1, jcgo_rcvrI2= (package_Utility__getSignedShort__BAI(
     data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
    offset+= (jint)2;
    if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillFront),
     l1) == (jint)32767L)
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillFront), l1)=
      JCGO_FIELD_NZACCESS(This, magic);
    }
   }
  }
  {
   jint i2;
   i2= 0;
   for (; i2 < k; i2++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, faceFillBack),
     jcgo_rcvrI1= i2, jcgo_rcvrI2= (package_Utility__getSignedShort__BAI(
     data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
     jcgo_rcvrI2);
    offset+= (jint)2;
    if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillBack),
     i2) == (jint)32767L)
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillBack), i2)=
      JCGO_FIELD_NZACCESS(This, magic);
    }
   }
  }
  {
   jint j2;
   j2= 0;
   for (; j2 < k; j2++)
   {
    jint k2;
    k2= (jint)((unsigned char)(JCGO_ARRAY_NZBACCESS(data, offset++)));
    if (k2 == 0)
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity), j2)=
      0;
    }
    else
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity), j2)=
      JCGO_FIELD_NZACCESS(This, magic);
    }
   }
  }
  {
   jint l2;
   l2= 0;
   for (; l2 < k; l2++)
   {
    jObject jcgo_rcvrL1;
    (jcgo_rcvrL1= (jObject)((jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
     0, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
     l2))), *(jintArr*)&JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
     faceVertices), l2)= (jintArr)jcgo_rcvrL1);
    {
     jint i3;
     i3= 0;
     for (; i3 < JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
      l2); i3++)
     {
      if (j < (jint)256)
      {
       jObject jcgo_rcvrL1;
       jint jcgo_rcvrI1;
       jint jcgo_rcvrI2;
       (jcgo_rcvrL1= (jObject)((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
        faceVertices), l2)), jcgo_rcvrI1= i3, jcgo_rcvrI2= (jint)((unsigned char)(JCGO_ARRAY_NZBACCESS(data,
        offset++))), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
        jcgo_rcvrI2);
      }
      else
      {
       jObject jcgo_rcvrL1;
       jint jcgo_rcvrI1;
       jint jcgo_rcvrI2;
       (jcgo_rcvrL1= (jObject)((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
        faceVertices), l2)), jcgo_rcvrI1= i3, jcgo_rcvrI2= (package_Utility__getUnsignedShort__BAI(
        data, offset)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1, jcgo_rcvrI1)=
        jcgo_rcvrI2);
       offset+= (jint)2;
      }
     }
    }
   }
  }
  JCGO_FIELD_NZACCESS(This, numFaces)= k;
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
 return This;
}

JCGO_NOSEP_FRWINL package_GameModel CFASTCALL
package_GameModel__new__BAIZ( jbyteArr data, jint offset, jboolean
 unused )
{
 JCGO_CLINIT_TRIG(package_GameModel__class);
 return package_GameModel__this__BAIZ(
  (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
  data, offset, unused);
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__allocate__II( package_GameModel This, jint numV,
 jint numF )
{
 {
  JCGO_FIELD_NZACCESS(This, vertexX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numV);
  JCGO_FIELD_NZACCESS(This, vertexY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numV);
  JCGO_FIELD_NZACCESS(This, vertexZ)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numV);
  JCGO_FIELD_NZACCESS(This, vertexIntensity)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numV);
  JCGO_FIELD_NZACCESS(This, vertexAmbience)= (jbyteArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jbyte),
   0, numV);
  JCGO_FIELD_NZACCESS(This, faceNumVertices)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  JCGO_FIELD_NZACCESS(This, faceVertices)= (jObjectArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   1, numF);
  JCGO_FIELD_NZACCESS(This, faceFillFront)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  JCGO_FIELD_NZACCESS(This, faceFillBack)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  JCGO_FIELD_NZACCESS(This, faceIntensity)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  JCGO_FIELD_NZACCESS(This, normalScale)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  JCGO_FIELD_NZACCESS(This, normalMagnitude)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, numF);
  if (!JCGO_FIELD_NZACCESS(This, projected))
  {
   JCGO_FIELD_NZACCESS(This, projectVertexX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, projectVertexY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, projectVertexZ)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, vertexViewX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, vertexViewY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
  }
  if (!JCGO_FIELD_NZACCESS(This, unpickable))
  {
   JCGO_FIELD_NZACCESS(This, isLocalPlayer)= (jbyteArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jbyte),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceTag)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
  }
  if (JCGO_FIELD_NZACCESS(This, autocommit))
  {
   JCGO_FIELD_NZACCESS(This, vertexTransformedX)= JCGO_FIELD_NZACCESS(This,
    vertexX);
   JCGO_FIELD_NZACCESS(This, vertexTransformedY)= JCGO_FIELD_NZACCESS(This,
    vertexY);
   JCGO_FIELD_NZACCESS(This, vertexTransformedZ)= JCGO_FIELD_NZACCESS(This,
    vertexZ);
  }
  else
  {
   JCGO_FIELD_NZACCESS(This, vertexTransformedX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, vertexTransformedY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
   JCGO_FIELD_NZACCESS(This, vertexTransformedZ)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numV);
  }
  if (!JCGO_FIELD_NZACCESS(This, unlit) || !JCGO_FIELD_NZACCESS(This,
   isolated))
  {
   JCGO_FIELD_NZACCESS(This, faceNormalX)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceNormalY)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceNormalZ)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
  }
  if (!JCGO_FIELD_NZACCESS(This, isolated))
  {
   JCGO_FIELD_NZACCESS(This, faceBoundLeft)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceBoundRight)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceBoundBottom)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceBoundTop)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceBoundNear)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
   JCGO_FIELD_NZACCESS(This, faceBoundFar)= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    0, numF);
  }
  JCGO_FIELD_NZACCESS(This, numFaces)= 0;
  JCGO_FIELD_NZACCESS(This, numVertices)= 0;
  JCGO_FIELD_NZACCESS(This, maxVerts)= numV;
  JCGO_FIELD_NZACCESS(This, maxFaces)= numF;
  JCGO_FIELD_NZACCESS(This, baseX)= JCGO_FIELD_NZACCESS(This, baseY)=
   JCGO_FIELD_NZACCESS(This, baseZ)= 0;
  JCGO_FIELD_NZACCESS(This, orientationYaw)= JCGO_FIELD_NZACCESS(This,
   orientationPitch)= JCGO_FIELD_NZACCESS(This, orientationRoll)= 0;
  JCGO_FIELD_NZACCESS(This, scaleFx)= JCGO_FIELD_NZACCESS(This, scaleFy)=
   JCGO_FIELD_NZACCESS(This, scaleFz)= (jint)256;
  JCGO_FIELD_NZACCESS(This, shearXy)= JCGO_FIELD_NZACCESS(This, shearXz)=
   JCGO_FIELD_NZACCESS(This, shearYx)= JCGO_FIELD_NZACCESS(This, shearYz)=
   JCGO_FIELD_NZACCESS(This, shearZx)= JCGO_FIELD_NZACCESS(This, shearZy)=
   (jint)256;
  JCGO_FIELD_NZACCESS(This, transformKind)= 0;
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__clear__( package_GameModel This )
{
 {
  JCGO_FIELD_NZACCESS(This, numFaces)= 0;
  JCGO_FIELD_NZACCESS(This, numVertices)= 0;
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__reduce__II( package_GameModel This, jint df, jint
 dz )
{
 {
  JCGO_FIELD_NZACCESS(This, numFaces)-= df;
  if (JCGO_FIELD_NZACCESS(This, numFaces) < 0)
  {
   JCGO_FIELD_NZACCESS(This, numFaces)= 0;
  }
  JCGO_FIELD_NZACCESS(This, numVertices)-= dz;
  if (JCGO_FIELD_NZACCESS(This, numVertices) < 0)
  {
   JCGO_FIELD_NZACCESS(This, numVertices)= 0;
  }
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__merge__L98u34AIZ( package_GameModel This, jObjectArr
 pieces, jint count, jboolean transState )
{
 {
  jint numF;
  jint numV;
  numF= 0;
  numV= 0;
  {
   jint i;
   i= 0;
   for (; i < count; i++)
   {
    numF+= JCGO_FIELD_ACCESS(package_GameModel, ((package_GameModel)JCGO_ARRAY_LACCESS(pieces,
     i)), numFaces);
    numV+= JCGO_FIELD_ACCESS(package_GameModel, ((package_GameModel)JCGO_ARRAY_NZLACCESS(pieces,
     i)), numVertices);
   }
  }
  (package_GameModel__allocate__II(
   This, numV, numF));
  if (transState)
  {
   JCGO_FIELD_NZACCESS(This, faceTransStateThing)= (jObjectArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
    1, numF);
  }
  {
   jint i;
   i= 0;
   for (; i < count; i++)
   {
    package_GameModel source;
    source= ((package_GameModel)JCGO_ARRAY_LACCESS(pieces, i));
    (JCGO_CALL_FINALF(source) package_GameModel__commit__(
     source));
    JCGO_FIELD_NZACCESS(This, lightAmbience)= JCGO_FIELD_NZACCESS(source,
     lightAmbience);
    JCGO_FIELD_NZACCESS(This, lightDiffuse)= JCGO_FIELD_NZACCESS(source,
     lightDiffuse);
    JCGO_FIELD_NZACCESS(This, lightDirectionX)= JCGO_FIELD_NZACCESS(source,
     lightDirectionX);
    JCGO_FIELD_NZACCESS(This, lightDirectionY)= JCGO_FIELD_NZACCESS(source,
     lightDirectionY);
    JCGO_FIELD_NZACCESS(This, lightDirectionZ)= JCGO_FIELD_NZACCESS(source,
     lightDirectionZ);
    JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= JCGO_FIELD_NZACCESS(source,
     lightDirectionMagnitude);
    {
     jint srcF;
     srcF= 0;
     for (; srcF < JCGO_FIELD_NZACCESS(source, numFaces); srcF++)
     {
      jintArr dstVs;
      jintArr srcVs;
      jint dstF;
      jObject jcgo_rcvrL1;
      jint jcgo_rcvrI1;
      jint jcgo_rcvrI2;
      dstVs= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
       0, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source, faceNumVertices),
       srcF));
      srcVs= ((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
       faceVertices), srcF));
      {
       jint v;
       v= 0;
       for (; v < JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source, faceNumVertices),
        srcF); v++)
       {
        jObject jcgo_rcvrL1;
        jint jcgo_rcvrI1;
        jint jcgo_rcvrI2;
        jint jcgo_rcvrI3;
        jint jcgo_rcvrI4;
        (jcgo_rcvrL1= (jObject)dstVs, jcgo_rcvrI1= v, jcgo_rcvrI2=
         (jcgo_rcvrI3= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
         vertexX), JCGO_ARRAY_IACCESS(srcVs, v)), jcgo_rcvrI4= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
         vertexY), JCGO_ARRAY_IACCESS(srcVs, v)), package_GameModel__vertexAt__III(
         This, jcgo_rcvrI3, jcgo_rcvrI4, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
         vertexZ), JCGO_ARRAY_IACCESS(srcVs, v)))), JCGO_ARRAY_NZIACCESS((jintArr)jcgo_rcvrL1,
         jcgo_rcvrI1)= jcgo_rcvrI2);
       }
      }
      dstF= (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
       faceNumVertices), srcF), jcgo_rcvrL1= (jObject)dstVs, jcgo_rcvrI2=
       JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source, faceFillFront),
       srcF), package_GameModel__createFace__IIAII(
       This, (jintArr)jcgo_rcvrL1, jcgo_rcvrI1, jcgo_rcvrI2, JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
       faceFillBack), srcF)));
      (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
       faceIntensity), srcF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
       faceIntensity), dstF)= jcgo_rcvrI1);
      (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
       normalScale), srcF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
       normalScale), dstF)= jcgo_rcvrI1);
      (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(source,
       normalMagnitude), srcF), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
       normalMagnitude), dstF)= jcgo_rcvrI1);
      if (transState)
      {
       if (count > (jint)1)
       {
        jObject jcgo_rcvrL1;
        (jcgo_rcvrL1= (jObject)((jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
         0, JCGO_ARRAY_LENGTH(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
         faceTransStateThing), srcF))) + (jint)1)), *(jintArr*)&JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
         faceTransStateThing), dstF)= (jintArr)jcgo_rcvrL1);
        JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
         faceTransStateThing), dstF)), 0)= i;
        {
         jint i2;
         i2= 0;
         for (; i2 < JCGO_ARRAY_LENGTH(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
          faceTransStateThing), srcF))); i2++)
         {
          jint jcgo_rcvrI1;
          (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
           faceTransStateThing), srcF)), i2), JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
           faceTransStateThing), dstF)), i2 + (jint)1)= jcgo_rcvrI1);
         }
        }
       }
       else
       {
        jObject jcgo_rcvrL1;
        (jcgo_rcvrL1= (jObject)((jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
         0, JCGO_ARRAY_LENGTH(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
         faceTransStateThing), srcF))))), *(jintArr*)&JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
         faceTransStateThing), dstF)= (jintArr)jcgo_rcvrL1);
        {
         jint j2;
         j2= 0;
         for (; j2 < JCGO_ARRAY_LENGTH(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
          faceTransStateThing), srcF))); j2++)
         {
          jint jcgo_rcvrI1;
          (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(source,
           faceTransStateThing), srcF)), j2), JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
           faceTransStateThing), dstF)), j2)= jcgo_rcvrI1);
         }
        }
       }
      }
     }
    }
   }
  }
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_STATIC jint CFASTCALL
package_GameModel__vertexAt__III( package_GameModel This, jint x,
 jint y, jint z )
{
 {
  {
   jint l;
   l= 0;
   for (; l < JCGO_FIELD_NZACCESS(This, numVertices); l++)
   {
    if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX), l) ==
     x && JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY), l) ==
     y && JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ), l) ==
     z)
    {
     return l;
    }
   }
  }
  if (JCGO_FIELD_NZACCESS(This, numVertices) >= JCGO_FIELD_NZACCESS(This,
   maxVerts))
  {
   return (-(jint)1);
  }
  else
  {
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX), JCGO_FIELD_NZACCESS(This,
    numVertices))= x;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY), JCGO_FIELD_NZACCESS(This,
    numVertices))= y;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ), JCGO_FIELD_NZACCESS(This,
    numVertices))= z;
   return JCGO_FIELD_NZACCESS(This, numVertices)++;
  }
 }
}

JCGO_NOSEP_STATIC jint CFASTCALL
package_GameModel__createVertex__III( package_GameModel This, jint
 i, jint j, jint k )
{
 {
  if (JCGO_FIELD_NZACCESS(This, numVertices) >= JCGO_FIELD_NZACCESS(This,
   maxVerts))
  {
   return (-(jint)1);
  }
  else
  {
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX), JCGO_FIELD_NZACCESS(This,
    numVertices))= i;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY), JCGO_FIELD_NZACCESS(This,
    numVertices))= j;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ), JCGO_FIELD_NZACCESS(This,
    numVertices))= k;
   return JCGO_FIELD_NZACCESS(This, numVertices)++;
  }
 }
}

JCGO_NOSEP_STATIC jint CFASTCALL
package_GameModel__createFace__IIAII( package_GameModel This, jintArr
 vs, jint n, jint front, jint back )
{
 {
  if (JCGO_FIELD_NZACCESS(This, numFaces) >= JCGO_FIELD_NZACCESS(This,
   maxFaces))
  {
   return (-(jint)1);
  }
  else
  {
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices), JCGO_FIELD_NZACCESS(This,
    numFaces))= n;
   *(jintArr*)&JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This, faceVertices),
    JCGO_FIELD_NZACCESS(This, numFaces))= vs;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillFront), JCGO_FIELD_NZACCESS(This,
    numFaces))= front;
   JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceFillBack), JCGO_FIELD_NZACCESS(This,
    numFaces))= back;
   JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
   return JCGO_FIELD_NZACCESS(This, numFaces)++;
  }
 }
}

JCGO_NOSEP_STATIC jObjectArr CFASTCALL
package_GameModel__split__IIIIIIIZ( package_GameModel This, jint unused1,
 jint unused2, jint pieceDx, jint pieceDz, jint rows, jint count, jint
 pieceMaxVertices, jboolean pickable )
{
 {
  jintArr pieceNV;
  jintArr pieceNF;
  jObjectArr pieces;
  (package_GameModel__commit__(
   This));
  pieceNV= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0,
   count);
  pieceNF= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0,
   count);
  {
   jint i;
   i= 0;
   for (; i < count; i++)
   {
    JCGO_ARRAY_NZIACCESS(pieceNV, i)= 0;
    JCGO_ARRAY_NZIACCESS(pieceNF, i)= 0;
   }
  }
  {
   jint f;
   f= 0;
   for (; f < JCGO_FIELD_NZACCESS(This, numFaces); f++)
   {
    jintArr vs;
    jint sumX;
    jint sumZ;
    jint n;
    jint p;
    jint jcgo_rcvrI1;
    sumX= 0;
    sumZ= 0;
    n= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
     f);
    vs= ((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This, faceVertices),
     f));
    {
     jint i;
     i= 0;
     for (; i < n; i++)
     {
      sumX+= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX),
       JCGO_ARRAY_IACCESS(vs, i));
      sumZ+= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ),
       JCGO_ARRAY_NZIACCESS(vs, i));
     }
    }
    p= (jcgo_rcvrI1= jcgo_div(sumX, (n * pieceDx)), jcgo_rcvrI1 + (jcgo_div(sumZ,
     (n * pieceDz))) * rows);
    JCGO_ARRAY_NZIACCESS(pieceNV, p)+= n;
    (JCGO_ARRAY_NZIACCESS(pieceNF, p))++;
   }
  }
  pieces= (jObjectArr)jcgo_newArray(JCGO_CLASSREF_OF(package_GameModel__class),
   0, count);
  {
   jint i;
   i= 0;
   for (; i < count; i++)
   {
    jObject jcgo_rcvrL1;
    jObject jcgo_rcvrL2;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    if (JCGO_ARRAY_NZIACCESS(pieceNV, i) > pieceMaxVertices)
    {
     JCGO_ARRAY_NZIACCESS(pieceNV, i)= pieceMaxVertices;
    }
    (jcgo_rcvrL1= (jObject)pieces, jcgo_rcvrI1= i, jcgo_rcvrL2= (jObject)(jcgo_rcvrI2=
     JCGO_ARRAY_NZIACCESS(pieceNV, i), package_GameModel__this__IIZZZZZ(
     (package_GameModel)jcgo_newObject((jvtable)&package_GameModel_methods),
     jcgo_rcvrI2, JCGO_ARRAY_NZIACCESS(pieceNF, i), (jboolean)jtrue,
     (jboolean)jtrue, (jboolean)jtrue, (jboolean)pickable, (jboolean)jtrue)),
     *(package_GameModel*)&JCGO_ARRAY_NZLACCESS((jObjectArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= (package_GameModel)jcgo_rcvrL2);
    JCGO_FIELD_ACCESS(package_GameModel, ((package_GameModel)JCGO_ARRAY_NZLACCESS(pieces,
     i)), lightDiffuse)= JCGO_FIELD_NZACCESS(This, lightDiffuse);
    JCGO_FIELD_ACCESS(package_GameModel, ((package_GameModel)JCGO_ARRAY_NZLACCESS(pieces,
     i)), lightAmbience)= JCGO_FIELD_NZACCESS(This, lightAmbience);
   }
  }
  {
   jint f;
   f= 0;
   for (; f < JCGO_FIELD_NZACCESS(This, numFaces); f++)
   {
    jintArr vs;
    jint sumX;
    jint sumZ;
    jint n;
    jint p;
    jint jcgo_rcvrI1;
    sumX= 0;
    sumZ= 0;
    n= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
     f);
    vs= ((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This, faceVertices),
     f));
    {
     jint i;
     i= 0;
     for (; i < n; i++)
     {
      sumX+= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX),
       JCGO_ARRAY_IACCESS(vs, i));
      sumZ+= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ),
       JCGO_ARRAY_NZIACCESS(vs, i));
     }
    }
    p= (jcgo_rcvrI1= jcgo_div(sumX, (n * pieceDx)), jcgo_rcvrI1 + (jcgo_div(sumZ,
     (n * pieceDz))) * rows);
    (package_GameModel__copyLighting__L98u34IAII(
     This, ((package_GameModel)JCGO_ARRAY_NZLACCESS(pieces, p)), vs,
     n, f));
   }
  }
  {
   jint p;
   p= 0;
   for (; p < count; p++)
   {
    jObject jcgo_rcvrL1;
    (jcgo_rcvrL1= (jObject)((package_GameModel)JCGO_ARRAY_NZLACCESS(pieces,
     p)), JCGO_CALL_FINALF((package_GameModel)jcgo_rcvrL1) package_GameModel__projectionPrepare__(
     (package_GameModel)jcgo_rcvrL1));
   }
  }
  return pieces;
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__setLight__ZIIIII( package_GameModel This, jint
 ambient, jint diffuse, jint x, jint y, jint z, jboolean gouraud )
{
 {
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)256 - ambient * (jint)4;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= ((jint)64 - diffuse) * (jint)16 +
   (jint)128;
  if (JCGO_FIELD_NZACCESS(This, unlit))
  {
   return;
  }
  {
   jint i;
   i= 0;
   for (; i < JCGO_FIELD_NZACCESS(This, numFaces); i++)
   {
    if (gouraud)
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity), i)=
      JCGO_FIELD_NZACCESS(This, magic);
    }
    else
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity), i)=
      0;
    }
   }
  }
  JCGO_FIELD_NZACCESS(This, lightDirectionX)= x;
  JCGO_FIELD_NZACCESS(This, lightDirectionY)= y;
  JCGO_FIELD_NZACCESS(This, lightDirectionZ)= z;
  JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= JCGO_JDOUBLE_TOJINT((java_lang_Math__sqrt__D(
   (jdouble)(x * x + y * y + z * z))));
  (package_GameModel__light__(
   This));
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__setLight__IIIII( package_GameModel This, jint ambience,
 jint diffuse, jint x, jint y, jint z )
{
 {
  JCGO_FIELD_NZACCESS(This, lightAmbience)= (jint)256 - ambience *
   (jint)4;
  JCGO_FIELD_NZACCESS(This, lightDiffuse)= ((jint)64 - diffuse) * (jint)16 +
   (jint)128;
  if (!JCGO_FIELD_NZACCESS(This, unlit))
  {
   JCGO_FIELD_NZACCESS(This, lightDirectionX)= x;
   JCGO_FIELD_NZACCESS(This, lightDirectionY)= y;
   JCGO_FIELD_NZACCESS(This, lightDirectionZ)= z;
   JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= JCGO_JDOUBLE_TOJINT((java_lang_Math__sqrt__D(
    (jdouble)(x * x + y * y + z * z))));
   (package_GameModel__light__(
    This));
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__setLight__III( package_GameModel This, jint x,
 jint y, jint z )
{
 {
  if (!JCGO_FIELD_NZACCESS(This, unlit))
  {
   JCGO_FIELD_NZACCESS(This, lightDirectionX)= x;
   JCGO_FIELD_NZACCESS(This, lightDirectionY)= y;
   JCGO_FIELD_NZACCESS(This, lightDirectionZ)= z;
   JCGO_FIELD_NZACCESS(This, lightDirectionMagnitude)= JCGO_JDOUBLE_TOJINT((java_lang_Math__sqrt__D(
    (jdouble)(x * x + y * y + z * z))));
   (package_GameModel__light__(
    This));
  }
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__setVertexAmbience__II( package_GameModel This,
 jint v, jint ambience )
{
 {
  JCGO_ARRAY_BACCESS(JCGO_FIELD_NZACCESS(This, vertexAmbience), v)=
   ((jbyte)ambience);
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__rotate__III( package_GameModel This, jint yaw,
 jint pitch, jint roll )
{
 {
  JCGO_FIELD_NZACCESS(This, orientationYaw)= (JCGO_FIELD_NZACCESS(This,
   orientationYaw) + yaw) & (jint)255;
  JCGO_FIELD_NZACCESS(This, orientationPitch)= (JCGO_FIELD_NZACCESS(This,
   orientationPitch) + pitch) & (jint)255;
  JCGO_FIELD_NZACCESS(This, orientationRoll)= (JCGO_FIELD_NZACCESS(This,
   orientationRoll) + roll) & (jint)255;
  (package_GameModel__determineTransformKind__(
   This));
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_INLINE void CFASTCALL
package_GameModel__orient__III( package_GameModel This, jint yaw,
 jint pitch, jint roll )
{
 {
  JCGO_FIELD_NZACCESS(This, orientationYaw)= yaw & (jint)255;
  JCGO_FIELD_NZACCESS(This, orientationPitch)= pitch & (jint)255;
  JCGO_FIELD_NZACCESS(This, orientationRoll)= roll & (jint)255;
  (package_GameModel__determineTransformKind__(
   This));
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__translate__III( package_GameModel This, jint x,
 jint y, jint z )
{
 {
  JCGO_FIELD_NZACCESS(This, baseX)+= x;
  JCGO_FIELD_NZACCESS(This, baseY)+= y;
  JCGO_FIELD_NZACCESS(This, baseZ)+= z;
  (package_GameModel__determineTransformKind__(
   This));
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_FRWINL void CFASTCALL
package_GameModel__place__III( package_GameModel This, jint x, jint
 y, jint z )
{
 {
  JCGO_FIELD_NZACCESS(This, baseX)= x;
  JCGO_FIELD_NZACCESS(This, baseY)= y;
  JCGO_FIELD_NZACCESS(This, baseZ)= z;
  (package_GameModel__determineTransformKind__(
   This));
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__determineTransformKind__( package_GameModel This
 )
{
 {
  if (JCGO_FIELD_NZACCESS(This, shearXy) != (jint)256 || JCGO_FIELD_NZACCESS(This,
   shearXz) != (jint)256 || JCGO_FIELD_NZACCESS(This, shearYx) != (jint)256 ||
   JCGO_FIELD_NZACCESS(This, shearYz) != (jint)256 || JCGO_FIELD_NZACCESS(This,
   shearZx) != (jint)256 || JCGO_FIELD_NZACCESS(This, shearZy) != (jint)256)
  {
   JCGO_FIELD_NZACCESS(This, transformKind)= (jint)4;
  }
  else
  {
   if (JCGO_FIELD_NZACCESS(This, scaleFx) != (jint)256 || JCGO_FIELD_NZACCESS(This,
    scaleFy) != (jint)256 || JCGO_FIELD_NZACCESS(This, scaleFz) !=
    (jint)256)
   {
    JCGO_FIELD_NZACCESS(This, transformKind)= (jint)3;
   }
   else
   {
    if (JCGO_FIELD_NZACCESS(This, orientationYaw) != 0 || JCGO_FIELD_NZACCESS(This,
     orientationPitch) != 0 || JCGO_FIELD_NZACCESS(This, orientationRoll) !=
     0)
    {
     JCGO_FIELD_NZACCESS(This, transformKind)= (jint)2;
    }
    else
    {
     if (JCGO_FIELD_NZACCESS(This, baseX) != 0 || JCGO_FIELD_NZACCESS(This,
      baseY) != 0 || JCGO_FIELD_NZACCESS(This, baseZ) != 0)
     {
      JCGO_FIELD_NZACCESS(This, transformKind)= (jint)1;
     }
     else
     {
      JCGO_FIELD_NZACCESS(This, transformKind)= 0;
     }
    }
   }
  }
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__light__( package_GameModel This )
{
 {
  jintArr normalX;
  jintArr normalY;
  jintArr normalZ;
  jintArr normalMagnitude;
  jint divisor;
  if (JCGO_FIELD_NZACCESS(This, unlit))
  {
   return;
  }
  divisor= JCGO_SHR_F(JCGO_FIELD_NZACCESS(This, lightDiffuse) * JCGO_FIELD_NZACCESS(This,
   lightDirectionMagnitude), (jint)8);
  {
   jint face;
   face= 0;
   for (; face < JCGO_FIELD_NZACCESS(This, numFaces); face++)
   {
    if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity),
     face) != JCGO_FIELD_NZACCESS(This, magic))
    {
     jint jcgo_rcvrI1;
     jint jcgo_rcvrI2;
     (jcgo_rcvrI1= jcgo_div((jcgo_rcvrI2= (jcgo_rcvrI2= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      faceNormalX), face) * JCGO_FIELD_NZACCESS(This, lightDirectionX),
      jcgo_rcvrI2 + JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNormalY),
      face) * JCGO_FIELD_NZACCESS(This, lightDirectionY)), jcgo_rcvrI2 +
      JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNormalZ), face) *
      JCGO_FIELD_NZACCESS(This, lightDirectionZ)), divisor), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      faceIntensity), face)= jcgo_rcvrI1);
    }
   }
  }
  normalX= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0,
   JCGO_FIELD_NZACCESS(This, numVertices));
  normalY= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0,
   JCGO_FIELD_NZACCESS(This, numVertices));
  normalZ= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint), 0,
   JCGO_FIELD_NZACCESS(This, numVertices));
  normalMagnitude= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, JCGO_FIELD_NZACCESS(This, numVertices));
  {
   jint k;
   k= 0;
   for (; k < JCGO_FIELD_NZACCESS(This, numVertices); k++)
   {
    JCGO_ARRAY_NZIACCESS(normalX, k)= 0;
    JCGO_ARRAY_NZIACCESS(normalY, k)= 0;
    JCGO_ARRAY_NZIACCESS(normalZ, k)= 0;
    JCGO_ARRAY_NZIACCESS(normalMagnitude, k)= 0;
   }
  }
  {
   jint face;
   face= 0;
   for (; face < JCGO_FIELD_NZACCESS(This, numFaces); face++)
   {
    if (JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceIntensity),
     face) == JCGO_FIELD_NZACCESS(This, magic))
    {
     {
      jint v;
      v= 0;
      for (; v < JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNumVertices),
       face); v++)
      {
       jint k1;
       jObject jcgo_rcvrL1;
       k1= JCGO_ARRAY_IACCESS(((jintArr)JCGO_ARRAY_LACCESS(JCGO_FIELD_NZACCESS(This,
        faceVertices), face)), v);
       (jcgo_rcvrL1= (void*)&JCGO_ARRAY_NZIACCESS(normalX, k1), *(jint*)jcgo_rcvrL1+=
        JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNormalX),
        face));
       (jcgo_rcvrL1= (void*)&JCGO_ARRAY_NZIACCESS(normalY, k1), *(jint*)jcgo_rcvrL1+=
        JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNormalY),
        face));
       (jcgo_rcvrL1= (void*)&JCGO_ARRAY_NZIACCESS(normalZ, k1), *(jint*)jcgo_rcvrL1+=
        JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, faceNormalZ),
        face));
       (JCGO_ARRAY_NZIACCESS(normalMagnitude, k1))++;
      }
     }
    }
   }
  }
  {
   jint v;
   v= 0;
   for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
   {
    if (JCGO_ARRAY_NZIACCESS(normalMagnitude, v) > 0)
    {
     jint jcgo_rcvrI1;
     jint jcgo_rcvrI2;
     (jcgo_rcvrI1= (jcgo_rcvrI2= (jcgo_rcvrI2= (jcgo_rcvrI2= JCGO_ARRAY_NZIACCESS(normalX,
      v) * JCGO_FIELD_NZACCESS(This, lightDirectionX), jcgo_rcvrI2 +
      JCGO_ARRAY_NZIACCESS(normalY, v) * JCGO_FIELD_NZACCESS(This,
      lightDirectionY)), jcgo_rcvrI2 + JCGO_ARRAY_NZIACCESS(normalZ,
      v) * JCGO_FIELD_NZACCESS(This, lightDirectionZ)), jcgo_div(jcgo_rcvrI2,
      (divisor * JCGO_ARRAY_NZIACCESS(normalMagnitude, v)))), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexIntensity), v)= jcgo_rcvrI1);
    }
   }
  }
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__apply__( package_GameModel This )
{
 {
  if (JCGO_FIELD_NZACCESS(This, transformState) == (jint)2)
  {
   JCGO_FIELD_NZACCESS(This, transformState)= 0;
   {
    jint v;
    v= 0;
    for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
    {
     jint jcgo_rcvrI1;
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
      v)= jcgo_rcvrI1);
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
      v)= jcgo_rcvrI1);
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
      v)= jcgo_rcvrI1);
    }
   }
   JCGO_FIELD_NZACCESS(This, x1)= JCGO_FIELD_NZACCESS(This, y1)= JCGO_FIELD_NZACCESS(This,
    z1)= (jint)-9999999L;
   JCGO_FIELD_NZACCESS(This, diameter)= JCGO_FIELD_NZACCESS(This, x2)=
    JCGO_FIELD_NZACCESS(This, y2)= JCGO_FIELD_NZACCESS(This, z2)= (jint)9999999L;
   return;
  }
  if (JCGO_FIELD_NZACCESS(This, transformState) == (jint)1)
  {
   JCGO_FIELD_NZACCESS(This, transformState)= 0;
   {
    jint v;
    v= 0;
    for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
    {
     jint jcgo_rcvrI1;
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
      v)= jcgo_rcvrI1);
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
      v)= jcgo_rcvrI1);
     (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ),
      v), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
      v)= jcgo_rcvrI1);
    }
   }
   if (JCGO_FIELD_NZACCESS(This, transformKind) >= (jint)2)
   {
    (package_GameModel__applyRotation__III(
     This, JCGO_FIELD_NZACCESS(This, orientationYaw), JCGO_FIELD_NZACCESS(This,
     orientationPitch), JCGO_FIELD_NZACCESS(This, orientationRoll)));
   }
   if (JCGO_FIELD_NZACCESS(This, transformKind) >= (jint)3)
   {
    (package_GameModel__applyScale__III(
     This, JCGO_FIELD_NZACCESS(This, scaleFx), JCGO_FIELD_NZACCESS(This,
     scaleFy), JCGO_FIELD_NZACCESS(This, scaleFz)));
   }
   if (JCGO_FIELD_NZACCESS(This, transformKind) >= (jint)4)
   {
    (package_GameModel__applyShear__IIIIII(
     This, JCGO_FIELD_NZACCESS(This, shearXy), JCGO_FIELD_NZACCESS(This,
     shearXz), JCGO_FIELD_NZACCESS(This, shearYx), JCGO_FIELD_NZACCESS(This,
     shearYz), JCGO_FIELD_NZACCESS(This, shearZx), JCGO_FIELD_NZACCESS(This,
     shearZy)));
   }
   if (JCGO_FIELD_NZACCESS(This, transformKind) >= (jint)1)
   {
    (package_GameModel__applyTranslate__III(
     This, JCGO_FIELD_NZACCESS(This, baseX), JCGO_FIELD_NZACCESS(This,
     baseY), JCGO_FIELD_NZACCESS(This, baseZ)));
   }
   (package_GameModel__computeBounds__(
    This));
   (package_GameModel__relight__(
    This));
  }
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__project__IIIIIIII( package_GameModel This, jint
 cameraX, jint cameraY, jint cameraZ, jint cameraPitch, jint cameraRoll,
 jint cameraYaw, jint viewDist, jint clipNear )
{
 {
  jint yawSin;
  jint yawCos;
  jint pitchSin;
  jint pitchCos;
  jint rollSin;
  jint rollCos;
  (package_GameModel__apply__(
   This));
  if (JCGO_FIELD_NZACCESS(This, z1) > JCGO_CLINIT_VARACC(package_Scene__class,
   package_Scene__frustumNearZ) || JCGO_FIELD_NZACCESS(This, z2) <
   package_Scene__furstumFarZ || JCGO_FIELD_NZACCESS(This, x1) > package_Scene__frustumMinX ||
   JCGO_FIELD_NZACCESS(This, x2) < package_Scene__frustumMaxX || JCGO_FIELD_NZACCESS(This,
   y1) > package_Scene__furstumMinY || JCGO_FIELD_NZACCESS(This, y2) <
   package_Scene__furstumMaxY)
  {
   JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jfalse;
   return;
  }
  JCGO_FIELD_NZACCESS(This, visible)= (jboolean)jtrue;
  yawSin= 0;
  yawCos= 0;
  pitchSin= 0;
  pitchCos= 0;
  rollSin= 0;
  rollCos= 0;
  if (cameraYaw != 0)
  {
   yawSin= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraYaw);
   yawCos= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraYaw +
    (jint)1024);
  }
  if (cameraRoll != 0)
  {
   rollSin= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraRoll);
   rollCos= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraRoll +
    (jint)1024);
  }
  if (cameraPitch != 0)
  {
   pitchSin= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraPitch);
   pitchCos= JCGO_ARRAY_IACCESS(package_GameModel__sine11, cameraPitch +
    (jint)1024);
  }
  {
   jint v;
   v= 0;
   for (; v < JCGO_FIELD_NZACCESS(This, numVertices); v++)
   {
    jint x;
    jint y;
    jint z;
    x= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     v) - cameraX;
    y= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     v) - cameraY;
    z= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     v) - cameraZ;
    if (cameraYaw != 0)
    {
     jint X;
     X= JCGO_SHR_F(y * yawSin + x * yawCos, (jint)15);
     y= JCGO_SHR_F(y * yawCos - x * yawSin, (jint)15);
     x= X;
    }
    if (cameraRoll != 0)
    {
     jint X;
     X= JCGO_SHR_F(z * rollSin + x * rollCos, (jint)15);
     z= JCGO_SHR_F(z * rollCos - x * rollSin, (jint)15);
     x= X;
    }
    if (cameraPitch != 0)
    {
     jint Y;
     Y= JCGO_SHR_F(y * pitchCos - z * pitchSin, (jint)15);
     z= JCGO_SHR_F(y * pitchSin + z * pitchCos, (jint)15);
     y= Y;
    }
    if (z >= clipNear)
    {
     jint jcgo_rcvrI1;
     (jcgo_rcvrI1= jcgo_div(JCGO_SHL_F(x, viewDist), z), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexViewX), v)= jcgo_rcvrI1);
    }
    else
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexViewX), v)=
      JCGO_SHL_F(x, viewDist);
    }
    if (z >= clipNear)
    {
     jint jcgo_rcvrI1;
     (jcgo_rcvrI1= jcgo_div(JCGO_SHL_F(y, viewDist), z), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This,
      vertexViewY), v)= jcgo_rcvrI1);
    }
    else
    {
     JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexViewY), v)=
      JCGO_SHL_F(y, viewDist);
    }
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, projectVertexX), v)=
     x;
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, projectVertexY), v)=
     y;
    JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, projectVertexZ), v)=
     z;
   }
  }
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__commit__( package_GameModel This )
{
 {
  (package_GameModel__apply__(
   This));
  {
   jint i;
   i= 0;
   for (; i < JCGO_FIELD_NZACCESS(This, numVertices); i++)
   {
    jint jcgo_rcvrI1;
    (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedX),
     i), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexX), i)=
     jcgo_rcvrI1);
    (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedY),
     i), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexY), i)=
     jcgo_rcvrI1);
    (jcgo_rcvrI1= JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexTransformedZ),
     i), JCGO_ARRAY_IACCESS(JCGO_FIELD_NZACCESS(This, vertexZ), i)=
     jcgo_rcvrI1);
   }
  }
  JCGO_FIELD_NZACCESS(This, baseX)= JCGO_FIELD_NZACCESS(This, baseY)=
   JCGO_FIELD_NZACCESS(This, baseZ)= 0;
  JCGO_FIELD_NZACCESS(This, orientationYaw)= JCGO_FIELD_NZACCESS(This,
   orientationPitch)= JCGO_FIELD_NZACCESS(This, orientationRoll)= 0;
  JCGO_FIELD_NZACCESS(This, scaleFx)= JCGO_FIELD_NZACCESS(This, scaleFy)=
   JCGO_FIELD_NZACCESS(This, scaleFz)= (jint)256;
  JCGO_FIELD_NZACCESS(This, shearXy)= JCGO_FIELD_NZACCESS(This, shearXz)=
   JCGO_FIELD_NZACCESS(This, shearYx)= JCGO_FIELD_NZACCESS(This, shearYz)=
   JCGO_FIELD_NZACCESS(This, shearZx)= JCGO_FIELD_NZACCESS(This, shearZy)=
   (jint)256;
  JCGO_FIELD_NZACCESS(This, transformKind)= 0;
 }
}

JCGO_NOSEP_STATIC package_GameModel CFASTCALL
package_GameModel__copy__( package_GameModel This )
{
 {
  jObjectArr pieces;
  package_GameModel gameModel;
  jcgo_arrtype2_GameMdl jcgo_stackobj1;
  pieces= JCGO_STACKOBJ_OBJARRNEW(jcgo_stackobj1, jObjectArr_methods,
   JCGO_CLASSREF_OF(package_GameModel__class), 1);
  *(package_GameModel*)&JCGO_ARRAY_NZLACCESS(pieces, 0)= This;
  gameModel= (package_GameModel__new__L98u34AI(
   pieces, (jint)1));
  JCGO_FIELD_NZACCESS(gameModel, depth)= JCGO_FIELD_NZACCESS(This,
   depth);
  JCGO_FIELD_NZACCESS(gameModel, transparent)= (jboolean)JCGO_FIELD_NZACCESS(This,
   transparent);
  return gameModel;
 }
}

JCGO_NOSEP_INLINE package_GameModel CFASTCALL
package_GameModel__copy__ZZZZ( package_GameModel This, jboolean autocommit,
 jboolean isolated, jboolean unlit, jboolean pickable )
{
 {
  jObjectArr pieces;
  package_GameModel gameModel;
  jcgo_arrtype2_GameMdl jcgo_stackobj1;
  pieces= JCGO_STACKOBJ_OBJARRNEW(jcgo_stackobj1, jObjectArr_methods,
   JCGO_CLASSREF_OF(package_GameModel__class), 1);
  *(package_GameModel*)&JCGO_ARRAY_NZLACCESS(pieces, 0)= This;
  gameModel= (package_GameModel__new__L98u34AIZZZZ(
   pieces, (jint)1, (jboolean)autocommit, (jboolean)isolated, (jboolean)unlit,
   (jboolean)pickable));
  JCGO_FIELD_NZACCESS(gameModel, depth)= JCGO_FIELD_NZACCESS(This,
   depth);
  return gameModel;
 }
}

JCGO_NOSEP_FRWINL void CFASTCALL
package_GameModel__copyPosition__L98u34( package_GameModel This, package_GameModel
 model )
{
 {
  JCGO_FIELD_NZACCESS(This, orientationYaw)= JCGO_FIELD_ACCESS(package_GameModel,
   model, orientationYaw);
  JCGO_FIELD_NZACCESS(This, orientationPitch)= JCGO_FIELD_NZACCESS(model,
   orientationPitch);
  JCGO_FIELD_NZACCESS(This, orientationRoll)= JCGO_FIELD_NZACCESS(model,
   orientationRoll);
  JCGO_FIELD_NZACCESS(This, baseX)= JCGO_FIELD_NZACCESS(model, baseX);
  JCGO_FIELD_NZACCESS(This, baseY)= JCGO_FIELD_NZACCESS(model, baseY);
  JCGO_FIELD_NZACCESS(This, baseZ)= JCGO_FIELD_NZACCESS(model, baseZ);
  (package_GameModel__determineTransformKind__(
   This));
  JCGO_FIELD_NZACCESS(This, transformState)= (jint)1;
 }
}

JCGO_NOSEP_STATIC void CFASTCALL
package_GameModel__class__0( void )
{
 JCGO_CLINIT_BEGIN(package_GameModel__class);
 {
  package_GameModel__sine9= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, (jint)512);
  package_GameModel__sine11= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, (jint)2048);
  package_GameModel__base64Alphabet= (jintArr)jcgo_newArray(JCGO_CORECLASS_FOR(OBJT_jint),
   0, (jint)256);
  {
   jint i;
   i= 0;
   for (; i < (jint)256; i++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)package_GameModel__sine9, jcgo_rcvrI1= i,
     jcgo_rcvrI2= JCGO_JDOUBLE_TOJINT(((java_lang_Math__sin__D(
     (jdouble)i * (jdouble)0.02454369)) * (jdouble)32768.0)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= jcgo_rcvrI2);
    (jcgo_rcvrL1= (jObject)package_GameModel__sine9, jcgo_rcvrI1= i +
     (jint)256, jcgo_rcvrI2= JCGO_JDOUBLE_TOJINT(((java_lang_Math__cos__D(
     (jdouble)i * (jdouble)0.02454369)) * (jdouble)32768.0)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= jcgo_rcvrI2);
   }
  }
  {
   jint j;
   j= 0;
   for (; j < (jint)1024; j++)
   {
    jObject jcgo_rcvrL1;
    jint jcgo_rcvrI1;
    jint jcgo_rcvrI2;
    (jcgo_rcvrL1= (jObject)package_GameModel__sine11, jcgo_rcvrI1=
     j, jcgo_rcvrI2= JCGO_JDOUBLE_TOJINT(((java_lang_Math__sin__D(
     (jdouble)j * (jdouble)0.00613592315)) * (jdouble)32768.0)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= jcgo_rcvrI2);
    (jcgo_rcvrL1= (jObject)package_GameModel__sine11, jcgo_rcvrI1=
     j + (jint)1024, jcgo_rcvrI2= JCGO_JDOUBLE_TOJINT(((java_lang_Math__cos__D(
     (jdouble)j * (jdouble)0.00613592315)) * (jdouble)32768.0)), JCGO_ARRAY_IACCESS((jintArr)jcgo_rcvrL1,
     jcgo_rcvrI1)= jcgo_rcvrI2);
   }
  }
  {
   jint j1;
   j1= 0;
   for (; j1 < (jint)10; j1++)
   {
    JCGO_ARRAY_IACCESS(package_GameModel__base64Alphabet, j1 + (jint)48)=
     j1;
   }
  }
  {
   jint k1;
   k1= 0;
   for (; k1 < (jint)26; k1++)
   {
    JCGO_ARRAY_IACCESS(package_GameModel__base64Alphabet, k1 + (jint)65)=
     (k1 + (jint)10);
   }
  }
  {
   jint l1;
   l1= 0;
   for (; l1 < (jint)26; l1++)
   {
    JCGO_ARRAY_IACCESS(package_GameModel__base64Alphabet, l1 + (jint)97)=
     (l1 + (jint)36);
   }
  }
  JCGO_ARRAY_IACCESS(package_GameModel__base64Alphabet, (jint)163)=
   (jint)62;
  JCGO_ARRAY_IACCESS(package_GameModel__base64Alphabet, (jint)36)=
   (jint)63;
 }
 JCGO_CLINIT_DONE(package_GameModel__class);
}

JCGO_NOSEP_DATA CONST struct package_GameModel_methods_s package_GameModel_methods=
{
 JCGO_CLASSREF_OF(package_GameModel__class),
 JCGO_GCJDESCR_INIT(package_GameModel_s, faceBoundFar)
 OBJT_package_GameModel,
 (JCGO_OBJSIZE_T)sizeof(struct package_GameModel_s),
 NULL,
 JCGO_CLINIT_INIT(package_GameModel__class__0)
 0,
 java_lang_Object__equals__Lo,
 java_lang_Object__hashCode__,
 java_lang_Object__toString__,
 java_lang_Object__finalize__
};

JCGO_NOSEP_DATA struct package_GameModel_class_s package_GameModel__class
 ATTRIBNONGC=
{
 {
  &java_lang_Class_methods,
  JCGO_MON_INIT
  JCGO_OBJREF_OF(*(java_lang_Object)&package_GameModel_methods),
  JCGO_STRREF_OF(jcgo_string1_GameMdl),
  JCGO_CLASSREF_OF(java_lang_Object__class),
  ((jObjectArr)JCGO_OBJREF_OF(jcgo_array3_Object)),
  0x1c1
 }
};

JCGO_NOSEP_GCDATA jintArr package_GameModel__sine9 ATTRIBGCBSS= jnull;

JCGO_NOSEP_GCDATA jintArr package_GameModel__sine11 ATTRIBGCBSS= jnull;

JCGO_NOSEP_GCDATA jintArr package_GameModel__base64Alphabet ATTRIBGCBSS=
 jnull;

JCGO_NOSEP_DATA CONST jcgo_arrtype28_GameShll jcgo_array3_GameMdl=
{
 (jvtable)&jbyteArr_methods,
 JCGO_MON_INIT
 9,
 {
  (jbyte)(jchar)71/*'G'*/, (jbyte)(jchar)97/*'a'*/, (jbyte)(jchar)109/*'m'*/,
   (jbyte)(jchar)101/*'e'*/, (jbyte)(jchar)77/*'M'*/, (jbyte)(jchar)111/*'o'*/,
   (jbyte)(jchar)100/*'d'*/, (jbyte)(jchar)101/*'e'*/, (jbyte)(jchar)108/*'l'*/
 }
};

JCGO_NOSEP_DATA JCGO_NOTHR_CONST struct java_lang_String_s jcgo_string1_GameMdl
 JCGO_THRD_ATTRNONGC=
{
 &java_lang_String_methods,
 JCGO_MON_INIT
 (java_lang_Object)JCGO_OBJREF_OF(jcgo_array3_GameMdl),
 0, 9, (jint)0xb21e8637L
};

#ifdef CHKALL_GameModel
#include "jcgochke.h"
#endif

#endif
