SA-MP Forums Archive
Object Stream 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: Object Stream distance (/showthread.php?tid=451969)



Object Stream distance - TheCrescendo - 19.07.2013

Hey guys, just wanted to ask you, is there some kind of crazy
streamer that can load huge interiors, without cutting the interior?
Most of my interiors are rly big, and the server can't load the farest objests. :3
Here are some screens, i know you love them xD






Re: Object Stream distance - Twizted - 19.07.2013

Are you using Incognito's?


Re: Object Stream distance - TheCrescendo - 19.07.2013

Quote:
Originally Posted by Twizted
Посмотреть сообщение
Are you using Incognito's?
Yep. :3 Works fine if the map is not so big, but most of my interiors look like this. :3


Re: Object Stream distance - Pottus - 19.07.2013

There is three things you can do.

1) If your using CreateDynamicObject() switch to CreateDynamicObjectEx() it has a drawdistance parameter that CreateDynamicObject() lacks in fact I NEVER would consider using CreateDynamicObject() for any reason it's the worst function in the the plugin.

2) You can increase the amount of object the streamer will draw.

Note: 800 should be good for most purposes (default is 500)
pawn Код:
Streamer_MaxItems(STREAMER_TYPE_OBJECT , 800);
Streamer_VisibleItems(STREAMER_TYPE_OBJECT , 800);
3) Make sure small objects have a lower stream/draw distance than the larger objects!

That is basically the triple crown solution (the first point should fix most problems)


Re: Object Stream distance - TheCrescendo - 19.07.2013

Quote:
Originally Posted by [uL]Pottus
Посмотреть сообщение
There is three things you can do.

1) If your using CreateDynamicObject() switch to CreateDynamicObjectEx() it has a drawdistance parameter that CreateDynamicObject() lacks in fact I NEVER would consider using CreateDynamicObject() for any reason it's the worst function in the the plugin.

2) You can increase the amount of object the streamer will draw.

Note: 800 should be good for most purposes (default is 500)
pawn Код:
Streamer_MaxItems(STREAMER_TYPE_OBJECT , 800);
Streamer_VisibleItems(STREAMER_TYPE_OBJECT , 800);
3) Make sure small objects have a lower stream/draw distance than the larger objects!

That is basically the triple crown solution (the first point should fix most problems)
Gonna try both, third is allready done, but, is there any way to convert CreateDynamicObject() to CreateDynamicObjectEx()? Preety nooby question, but nvm. x)


Re: Object Stream distance - Babul - 19.07.2013

set the stream distance for small objects to al ower value, they arent important as theyre almost out of sight. theres the "model sizes" include somewhere, i had excellent results using that. give it a try!
(you might need to change all Create(Dynamic)Object lines to use a formula/preset distance tho...


Re: Object Stream distance - TheCrescendo - 19.07.2013

Quote:
Originally Posted by Babul
Посмотреть сообщение
set the stream distance for small objects to al ower value, they arent important as theyre almost out of sight. theres the "model sizes" include somewhere, i had excellent results using that. give it a try!
(you might need to change all Create(Dynamic)Object lines to use a formula/preset distance tho...
Yeh, knew about that one, but don't realy have enough time to change all of the lines, so gonna try diferent fixes, and if nothing works, gues i will have to do that. :3


Re: Object Stream distance - Babul - 21.07.2013

https://sampforum.blast.hk/showthread.php?tid=407909
^do it now. its a waste of time trying to modify >1000 lines for objects to be another fixed value.
if you use the include, and use a proper formula (i mentioned a 1:25 ratio in tha thread, or similar value). a little fix for really small objects like guns, flowers, a hotdog maybe, is to add a 10-25 units value to each object so they are visible from at least that (25 unit) distance.

benefits: when the formula still causes popups, then changing it = changing all objects. its even possible to raise/lower the distances while the objects are spawned, but thats a tricky thing to work with (bandwidth,desyncs etc).


Re: Object Stream distance - Birdkid1999 - 21.07.2013

Had this problem, I suggest going into your script and taking out unneeded mapping, did the trick for me, least it will help.


Re: Object Stream distance - Threshold - 21.07.2013

CTRL + H is your friend.

Search for 'CreateDynamicObject(', replace with 'CreateDynamicObjectEx('. (Add the brackets, so you don't accidentally replace another CreateDynamicObjectEx, and end up with CreateDynamicObjectExEx(...)

Then you will just have to add in the stream distances, which I'm sure nothing a quick copy and paste cannot fix. If you're not willing to do it, then I will do it for you in like 5 minutes max.