SA-MP Forums Archive
see object from large distance. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: see object from large distance. (/showthread.php?tid=476002)



see object from large distance. - audriuxxx - 16.11.2013

Hi,

How to make object distance, player can see a specic object from very large distance? for ex: you can see object from 1000 metres, because now limit is 300 metres. But i saw in 0.3d update or whatever, you can do it, but now i don't remember how to do it..


Re: see object from large distance. - [WA]iRonan - 16.11.2013

You set the draw distance in server.cfg (distance is standard 300) to whatever you like


Re: see object from large distance. - Beckett - 16.11.2013

Код:
CreateObject(modelid, Float:X, Float:Y, Float:Z, Float:rX, Float:rY, Float:rZ, Float:DrawDistance)



Re: see object from large distance. - audriuxxx - 16.11.2013

Can i do it?

CreateDynamicObject(modelid, x, y, z, rx, ry,rz, -1, -1, -1, 2000.0);

And if i set in server.cfg value more than 300-400 like 1000, i think value will come back to initial?


Re: see object from large distance. - audriuxxx - 16.11.2013

UP...


Re: see object from large distance. - Konstantinos - 16.11.2013

The last parameter in CreateDynamicObject is stream distance, not draw distance. However you can change the draw distance to a dynamic object by using Streamer_SetFloatData function.

For example:
pawn Код:
stock AddDynamicObject( modelid, Float: x, Float: y, Float: z, Float: rx, Float: ry, Float: rz, worldid = -1, interiorid = -1, playerid = -1, Float: streamdistance = 300.0, Float: drawdistance = 300.0 )
{
    new
        objectid
    ;
    objectid = CreateDynamicObject( modelid, x, y, z, rx, ry, rz, worldid, interiorid, playerid, streamdistance );
    Streamer_SetFloatData( STREAMER_TYPE_OBJECT, objectid, E_STREAMER_DRAW_DISTANCE, drawdistance );
    return objectid;
}
You can now use draw distance as whatever value you want (by default is set to 300.0).


Re: see object from large distance. - Pottus - 16.11.2013

Objects look shitty from far distances keep in mind as well


Re: see object from large distance. - Nourdin - 16.11.2013

Open server.cfg and check for the draw distance, set the draw distance to the value of the metres. After that restart your server and it must work then