KraZ Posted November 19, 2012 Share Posted November 19, 2012 How would i set a timer and show the same time to everyone, So say someone has been in a game for like 5 minutes and someone joins late, how would i show them the current time left of the game and not restart the timer? Link to comment
Renkon Posted November 19, 2012 Share Posted November 19, 2012 You can use setElementData Link to comment
Moderators IIYAMA Posted November 19, 2012 Moderators Share Posted November 19, 2012 https://wiki.multitheftauto.com/wiki/SetTimer https://wiki.multitheftauto.com/wiki/GetTimers https://wiki.multitheftauto.com/wiki/OnResourceStart --when this script is loaded, if you want to know the time when he joins. (also pre trigger to prevent the client isn't loaded bevore the server triggers) https://wiki.multitheftauto.com/wiki/TriggerClientEvent and as Rekon said: https://wiki.multitheftauto.com/wiki/SetElementData -- https://wiki.multitheftauto.com/wiki/GetElementData (the client can deside for him self) or use a trigger to deside the server when he must see the time. Elementdata will be set on serverside. When you need it, you can easy ask the time from the server when you use getElementData. But Element data can be laggy.(I never use it) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now