SA-MP Forums Archive
Can't see objects from far. - 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: Can't see objects from far. (/showthread.php?tid=461393)



Can't see objects from far. - dorperez - 01.09.2013

Help guys,Its really important for me,I can't see the objects from 10 meters something like that,I need to get close the objects in order to see them..

Help guys,I am using streamer plugin and the normal createobject.


Re: Can't see objects from far. - bensmart469 - 01.09.2013

Convert to CreateDynamicObject. You can also increase the stream distance with CreateDynamicObject. (see below)
Parameters:
pawn Код:
(modelid, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 200.0);
Example:
pawn Код:
CreateDynamicObject(19313, 0,0,30, 0,0,0, 0,0, -1, 1000); // Create an object in blueberry, with a stream distance of 1000



Re: Can't see objects from far. - dorperez - 01.09.2013

Quote:
Originally Posted by bensmart469
Посмотреть сообщение
Convert to CreateDynamicObject. You can also increase the stream distance with CreateDynamicObject. (see below)
Parameters:
pawn Код:
(modelid, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 200.0);
Example:
pawn Код:
CreateDynamicObject(19313, 0,0,30, 0,0,0, 0,0, -1, 1000); // Create an object in blueberry, with a stream distance of 1000
I did it bro but it doesnt worked .. :\

Any help ?


Re: Can't see objects from far. - bensmart469 - 01.09.2013

Show me one line, as an example.


Re: Can't see objects from far. - davve95 - 01.09.2013

I think it's the draw distance..
(If it's with CreateObject)..

You can read about it here:

https://sampwiki.blast.hk/wiki/CreatePlayerObject


Re: Can't see objects from far. - dorperez - 01.09.2013

Quote:
Originally Posted by bensmart469
Посмотреть сообщение
Show me one line, as an example.
Quote:
Originally Posted by davve95
Посмотреть сообщение
I think it's the draw distance..
(If it's with CreateObject)..

You can read about it here:

https://sampwiki.blast.hk/wiki/CreatePlayerObject
I know what it is bro but its also in the plugin ..

pawn Код:
CreateDynamicObject(19378,1724.5200000,-1765.3600000,17.6300000,0.0000000,0.0000000,88.2000000); //



Re: Can't see objects from far. - Pottus - 01.09.2013

There are two ways to this actually, and indeed the parameter you need is drawdistance and not stream distance.

1.) Use CreateDyanmicObjectEx() it has a a drawdistance parameter
2.) Use Streamer_SetFloatData() example.


pawn Код:
new ObjectID = CreateDynamicObject(19378,1724.5200000,-1765.3600000,17.6300000,0.0000000,0.0000000,88.2000000);
Streamer_SetFloatData(STREAMER_TYPE_OBJECT, ObjectID, E_STREAMER_DRAW_DISTANCE, 300.0);



Re: Can't see objects from far. - dorperez - 01.09.2013

Quote:
Originally Posted by [uL]Pottus
Посмотреть сообщение
There are two ways to this actually, and indeed the parameter you need is drawdistance and not stream distance.

1.) Use CreateDyanmicObjectEx() it has a a drawdistance parameter
2.) Use Streamer_SetFloatData() example.


pawn Код:
new ObjectID = CreateDynamicObject(19378,1724.5200000,-1765.3600000,17.6300000,0.0000000,0.0000000,88.2000000);
Streamer_SetFloatData(STREAMER_TYPE_OBJECT, ObjectID, E_STREAMER_DRAW_DISTANCE, 300.0);
Thank you bro but I have tones of objects on my gm and I can't do it for each one ... do you have another sugession?


Re: Can't see objects from far. - bensmart469 - 01.09.2013

Easy way:
Select all of the object lines - make sure you do this first
Press CTRL + h
Tick 'selected text only' (THIS IS IMPORTANT)
Put ); in the top box
And put -1, -1, -1, 300); in the bottom box.
Click 'ok'
Click 'yes to all'
Done

Makes it quicker and easier to do


Re: Can't see objects from far. - Pottus - 01.09.2013

You could also make your own map loader and just change the function call if it's really a problem.