Help me about coding "Objects Loaded"
#1

How can i show "Objects Loaded" text when all objects loaded?
Reply
#2

printf("Objects Loaded");

*me shrugs
Reply
#3

Quote:
Originally Posted by mprofitt
printf("Objects Loaded");

*me shrugs
I mean freezes player and doesn't unfreeze until objects loaded
Reply
#4

Quote:
Originally Posted by [XL
Fukara ]
Quote:
Originally Posted by mprofitt
printf("Objects Loaded");

*me shrugs
I mean freezes player and doesn't unfreeze until objects loaded
Contrary to popular belief, objects are loaded instantly. The only instance of objects not doing so is when a streamer is involved and is running on a timer. It's actually dumbfounded me as to why Object Streamers don't have a built-in LoadObjectsInArea(playerid,x,y,z) like function that would load the objects before the player is teleported there.
Reply
#5

Loading time depends on speed of CPU, they aren't loaded instantly because it takes time to calculate matrices(vectors and stuff like that) for every object. Projection, view matrix, etc. This type of loading is done by your graphic card & DirectX3D. Streamers are server-side so it needs time to transfer all packets AND do above.
Reply
#6

The viewing matrices take time to load, but the litteral collision model is loaded faster than the player being placed there. Ever hit an invisible building while flying?
Reply
#7

So, to help this guy out... he wants a timer that freezes the player while objects are loading..
so:
under #include <a_samp>
forward Freezeobj(i);

On the commands, like teleports to places with objects put:
SetTimerEx("Freezeobj",5000,0,"d",playerid);
so that will freeze player for 5000 miliseconds

and at very end of your script put
public Freezeobj(i) TogglePlayerControllable(i,1);

Should work now

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)