You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+13-16Lines changed: 13 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,18 +19,17 @@
19
19
20
20
## What is this?
21
21
22
-
**This is a library which provides easy and advanced timers for module
22
+
**A library which provides easy and advanced timers for module
23
23
developers.**
24
24
25
25
This project is inspired by
26
-
[mk's timer library](https://atelier801.com/topic?f=6&t=875052), so make sure to
27
-
support that also:heart:
26
+
[mk's timer library](https://atelier801.com/topic?f=6&t=875052), make sure to
27
+
support that project too:heart:
28
28
29
29
**_Background_**
30
30
31
-
Since normal players - who aren't module members are not allowed to use tfm
32
-
module apis timers (`system.newTimer` and `system.removeTimer`) I decided to
33
-
create a brand new and an advanced timer system for all!
31
+
As normal players - who aren't in module team - aren't allowed to use the Module API's timers (`system.newTimer` and `system.removeTimer`), I decided to
32
+
create a brand new, advanced timer system for the benefit of all!
34
33
35
34
**_There are many capabilities for these timers_**
36
35
@@ -43,7 +42,7 @@ create a brand new and an advanced timer system for all!
43
42
44
43
## How to use?
45
44
46
-
In order to use this library you need to insert this libraries code in top of
45
+
To use this library you need to insert this libraries code in top of
47
46
your code.
48
47
49
48
[Use the full code _(Recommended for studying)_](https://raw.githubusercontent.com/Seniru/Timers4TFM/master/src/timer.lua)
@@ -59,12 +58,10 @@ your code.
59
58
```lua
60
59
--insert the library code here
61
60
62
-
tfm.exec.newGame(0) -- You need to load a new map to use this appropriately
63
-
64
61
localtimer1=Timer("timer1", function() end, 5000, false) -- Creating a very basic timer with a timeout value of 5000
65
62
66
-
functioneventLoop(tc, tr)
67
-
Timer.run(tc) -- You need to call this method inside eventLoop to start and process timers
63
+
functioneventLoop()
64
+
Timer.process() -- You need to call this method inside eventLoop to start and process timers
68
65
end
69
66
70
67
@@ -85,8 +82,8 @@ end
85
82
86
83
Timer("callback", greet, 2000, false, "Seniru", true) --setting the callback to our greet function and pass "Seniru" and true as arguments
0 commit comments