Code:
#include <amxmodx>
#include <fakemeta>
//#include <hamsandwich>
//#include <D7Debug>
public plugin_init()
{
register_plugin("D7 Render Entities Map", "0.0.5", "D i 5 7 i n c T")
set_pev(0, pev_rendermode, kRenderTransTexture);
set_pev(0, pev_renderamt, 128.0)
new iIDEnt = -1, iSzLenght;
while ((iIDEnt = engfunc(EngFunc_FindEntityInSphere, iIDEnt, Float:{ 0.0, 0.0, 0.0 }, 9000.0)) != 0)
{
if (!pev_valid(iIDEnt))
continue;
static szEntInfo[32];
pev(iIDEnt, pev_classname, szEntInfo, charsmax(szEntInfo))
//ftD7Log(_, _, "[plugin_init] iIDEnt: %d. Class name: ^"%s^".", iIDEnt, szEntInfo)
pev(iIDEnt, pev_model, szEntInfo, charsmax(szEntInfo))
//ftD7Log(_, _, "[plugin_init] iIDEnt: %d. Model: ^"%s^".^n", iIDEnt, szEntInfo)
if (szEntInfo[0] != '*')
{
iSzLenght = strlen(szEntInfo);
if (iSzLenght < 4)
continue;
if (equali(szEntInfo[iSzLenght - 4], ".mdl"))
{
set_pev(iIDEnt, pev_rendermode, kRenderNormal)
set_pev(iIDEnt, pev_renderfx, kRenderFxGlowShell)
set_pev(iIDEnt, pev_rendercolor, Float:{ 255.0, 255.0, 255.0 })
set_pev(iIDEnt, pev_renderamt, 15.0)
}
else if (equali(szEntInfo[iSzLenght - 4], ".spr"))
{
set_pev(iIDEnt, pev_renderamt, 191.0)
}
}
else
{
set_pev(iIDEnt, pev_rendermode, kRenderTransTexture);
set_pev(iIDEnt, pev_renderamt, 128.0)
}
}
}