Posts: 131
Threads: 66
Joined: May 2016
Reputation:
0
Hey!
I'm having a problem with Textdraw being shown without it being called in any way.
So basically, I made some global textdraws, wrote their code under "OnGameModeInit" and I got timer set to show them 5 seconds after players register/login's but they already show as soon as register/login screen appears.. Any fixes ?
Posts: 4,885
Threads: 57
Joined: Jun 2012
Reputation:
0
Lets see that timer and function which the timer calls.
Posts: 4,885
Threads: 57
Joined: Jun 2012
Reputation:
0
Okay so the problem is likely inconsistent client load times or you set that timer at the wrong time (wrong callback?). You should look for a better time to activate this timer that gives better consistency.
Posts: 4,885
Threads: 57
Joined: Jun 2012
Reputation:
0
Oh I know why duh! You need to save your timer to a variable and make sure that you kill the timer! Someone is disconnecting quick but that timer still runs for the next player connecting.
Posts: 261
Threads: 32
Joined: Dec 2018
Actually, there is no need for the timer imho.
Just show the textdraw after the register/login message (if you have one), or if you don't, after setting all variables and similar.
Then hide it after they spawn or make them hide by pressing MMB or any key you wish.
Posts: 261
Threads: 32
Joined: Dec 2018
Quote:
Originally Posted by NoteND
I made timer for a reason, since I use interpolatecamera for cinematic, and I want textdraws to show after camera stops moving.. and I couldnt find option like "OnCameraStopMoving" so I used timer.
|
Well you never said about InterpolateCameraPos...