Forum

> > CS2D > Scripts > Time Script
Forums overviewCS2D overview Scripts overviewLog in to reply

English Time Script

11 replies
To the start Previous 1 Next To the start

old Time Script

Marcell
Super User Off Offline

Quote
Hi!
Possible to make a time script with real time?

ex:. When morning in the real life in the game is fully bright
and when night in real life in game will be dark, but the lights of course will working(mean to flashlight)

of course the hours and minutes will be real

old Re: Time Script

Alistaire
User Off Offline

Quote
Well, it will only work for one timezone, if you didn't think about that already.

old Re: Time Script

Marcell
Super User Off Offline

Quote
yes... i know but if someone who download the script and change the timezone in the script, hope it work for his/"her"

old Re: Time Script

Alistaire
User Off Offline

Quote
So. You want us to make you a script so that you can post it in the file archive?

old Re: Time Script

Apache uwu
User Off Offline

Quote
@user Alistaire: It would be possible for multiple timezones if it's only the scenery.

For ex. Player 1 could set their time to like 2:00PM and it would be bright out, Player 2 could set their time to 12:00AM and it would be dark out.

Images set specifically for different users.

--

Now to the other question, it is possible to find the current time of the server, not the client.

sysTime=os.time()

old Re: Time Script

Alistaire
User Off Offline

Quote
@user Apache uwu

That's why I said it's only for 1 timezone. You don't know the timezone of a normal player.

Also, individual images with Lua lag like shit.

old Re: Time Script

Apache uwu
User Off Offline

Quote
Players can popup a menu to set their timezone once.

And yeah, this will lag your client just by rendering the image over the entire map. Your best option would be to render via hud.

cs2d lua cmd image

Mode 2: HUD image (covering everything, part of the interface)

old Re: Time Script

Alistaire
User Off Offline

Quote
user Apache uwu has written
Players can popup a menu to set their timezone once.

And yeah, this will lag your client just by rendering the image over the entire map. Your best option would be to render via hud.

cs2d lua cmd image

Mode 2: HUD image (covering everything, part of the interface)


Altho it's too easy to cheat that way because you can reset your timezone etc.

old Re: Time Script

Apache uwu
User Off Offline

Quote
Well it is only for realism, if players don't want it to be all dark they can just set it differently.

With a USGN -- where they probably do have one because this is probably used for RP/citylife, you only can set the timezone once, which means you're going to hit a point where its all dark anyway.

As well, if you don't have a USID, you can't set the timezone.

old Re: Time Script

Alistaire
User Off Offline

Quote
user Apache uwu has written
Well it is only for realism, if players don't want it to be all dark they can just set it differently.

With a USGN -- where they probably do have one because this is probably used for RP/citylife, you only can set the timezone once, which means you're going to hit a point where its all dark anyway.

As well, if you don't have a USID, you can't set the timezone.


If you login without USGN your USGN is 0, which causes the save files to get fucked up.

old Re: Time Script

Marcell
Super User Off Offline

Quote
But if the server accept only USGN users... its working

old Re: Time Script

Alistaire
User Off Offline

Quote
user Marcell has written
But if the server accept only USGN users... its working


Well you'll need a lot of code and a really good internet connection to make it work with the individual shit. Else it works splendid.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview