Page 1 of 1

[Mod] Clock Mod [0.1] [clock]

PostPosted: Thu Apr 03, 2014 20:50
by Mitroman
This is my first Mod. It adds a clock into the game. When you leftclick (holding the clock) it will say the "time": Midnight, Midday, ... .

Crafting:
[ ] [G] [ ]
[G] [S] [G]
[ ] [G] [ ]
G = gold ingot
S = steel ingot

Depends: default

License: CC-BY-SA 3.0 (DE)

Download (ZIP):
0.1v https://github.com/Mitroman/Clock-Mod/archive/master.zip

Code: https://github.com/Mitroman/Clock-Mod

Bugs:
- It could be possible that the clock nothing say because I could forget to programm this time.

Screenshot:
https://github.com/Mitroman/Clock-Mod/blob/master/screenshot.png?raw=true

Ideas, help, ... would be good :)

PostPosted: Thu Apr 03, 2014 20:52
by hoodedice
Your title should be formatted as:

[MOD] Clock mod [0.1] [clock]

And we need a screenshot.

BTW, code is short and sweet. I'll try out your mod later.

PostPosted: Thu Apr 03, 2014 21:49
by Evergreen
Very nice! Very simple code and idea, I like it.

PostPosted: Fri Apr 04, 2014 05:59
by Bas080
This is a good and server friendly solution. For better time of day gradient add the
https://en.wikipedia.org/wiki/Four_Times_of_the_Day

Absolutley not necessary, but some people like to have diamond watches. Blang blang.

PostPosted: Fri Apr 04, 2014 11:31
by Krock
Hmm that clock is not very useful because I can see the current time when I look out of a window.
Still a nice beginning with modding.

PostPosted: Fri Apr 04, 2014 11:41
by mcfan
But it is good for when your mining - and... it is somewhat like MC.

PostPosted: Fri Apr 04, 2014 12:02
by Calinou
I would like to see a mod that permanently reminders the time somewhere on the screen instead. Could be done in C++ (preferred for accuracy) or Lua. You may say it's cheating, but there are various other ways (glitches, asking people, calculating time...) to get the time of day already.

PostPosted: Fri Apr 04, 2014 13:00
by hoodedice
mcfan wrote:But it is good for when your mining - and... it is somewhat like MC.


Please note that we are NOT trying to make a Minecraft clone here. Just saying.
Calinou wrote:I would like to see a mod that permanently reminders the time somewhere on the screen instead. Could be done in C++ (preferred for accuracy) or Lua. You may say it's cheating, but there are various other ways (glitches, asking people, calculating time...) to get the time of day already.


Hmm, do you think this culd be done with the current HUD API?

PostPosted: Fri Apr 04, 2014 13:35
by Jordach
Calinou wrote:You may say it's cheating, but there are various other ways (glitches, asking people, calculating time...) to get the time of day already.
Look at the sun / moon. *Walks off.*

PostPosted: Fri Apr 04, 2014 14:35
by mimilus
Maybe you could look here : https://github.com/Pitriss/overridemodpack/tree/master/hudclock

Works with 0.4.9

PostPosted: Fri Apr 04, 2014 17:07
by pop_harte
good mod but i only play xanadu

PostPosted: Sat Apr 05, 2014 13:06
by Mitroman
hoodedice wrote:Your title should be formatted as:

[MOD] Clock mod [0.1] [clock]

And we need a screenshot.

BTW, code is short and sweet. I'll try out your mod later.


Thanks. :)
I will add a screenshot.

PostPosted: Sat Apr 05, 2014 13:19
by Mitroman
Krock wrote:Hmm that clock is not very useful because I can see the current time when I look out of a window.
Still a nice beginning with modding.


Yeah. But when you are mining and you want know the time without going out so... :).

PostPosted: Sat Apr 05, 2014 13:20
by Mitroman
mimilus wrote:Maybe you could look here : https://github.com/Pitriss/overridemodpack/tree/master/hudclock

Works with 0.4.9


Yeah. But this is my first mod, so I am not the best mod-make of the world xD. :)

PostPosted: Sat Apr 05, 2014 20:49
by Calinou
hoodedice wrote:
mcfan wrote:But it is good for when your mining - and... it is somewhat like MC.


Please note that we are NOT trying to make a Minecraft clone here. Just saying.
Calinou wrote:I would like to see a mod that permanently reminders the time somewhere on the screen instead. Could be done in C++ (preferred for accuracy) or Lua. You may say it's cheating, but there are various other ways (glitches, asking people, calculating time...) to get the time of day already.


Hmm, do you think this culd be done with the current HUD API?


Yes, but very inefficient, especially if you want an accurate clock. You would have to update it often.