Exemplo n.º 1
0
        static void R_RenderWorld()
        {
            int i;

            model.model_t clmodel;

            if (btofpolys == null)
            {
                btofpolys = new btofpoly_t[MAX_BTOFPOLYS];
                for (int kk = 0; kk < MAX_BTOFPOLYS; kk++)
                {
                    btofpolys[kk] = new btofpoly_t();
                }
                pbtofpolys = btofpolys;
            }

            currententity = client.cl_entities[0];
            mathlib.VectorCopy(r_origin, ref modelorg);
            clmodel            = currententity.model;
            r_pcurrentvertbase = clmodel.vertexes;

            R_RecursiveWorldNode(clmodel.nodes[0], 15);

            // if the driver wants the polygons back to front, play the visible ones back
            // in that order
            if (r_worldpolysbacktofront)
            {
                for (i = numbtofpolys - 1; i >= 0; i--)
                {
                    R_RenderPoly(btofpolys[i].psurf, btofpolys[i].clipflags);
                }
            }
        }
Exemplo n.º 2
0
        static void R_RenderWorld()
        {
            int			    i;
            model.model_t	clmodel;

            if (btofpolys == null)
            {
                btofpolys = new btofpoly_t[MAX_BTOFPOLYS];
                for (int kk = 0; kk < MAX_BTOFPOLYS; kk++) btofpolys[kk] = new btofpoly_t();
                pbtofpolys = btofpolys;
            }

            currententity = client.cl_entities[0];
            mathlib.VectorCopy (r_origin, modelorg);
            clmodel = currententity.model;
            r_pcurrentvertbase = clmodel.vertexes;

            R_RecursiveWorldNode (clmodel.nodes[0], 15);

            // if the driver wants the polygons back to front, play the visible ones back
            // in that order
            if (r_worldpolysbacktofront)
            {
                for (i=numbtofpolys-1 ; i>=0 ; i--)
                {
                    R_RenderPoly (btofpolys[i].psurf, btofpolys[i].clipflags);
                }
            }
        }