Skip to content

Commit 51a82bc

Browse files
committed
First commit
1 parent e7b8cb9 commit 51a82bc

38 files changed

Lines changed: 973 additions & 62 deletions

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Change Log
22

3-
## [0.0.0-beta] - MM DD, YYYY
3+
## [0.0.0-beta] - Sept 28, 2024
44
- First commit

CHANGELOG.md.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CONTRIBUTING.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Contributing to MyPackage
22

3-
First off, thank you for considering contributing to MyPackage. Any contributions you make are **greatly appreciated**.
3+
First off, thank you for considering contributing to the Timers package. Any contributions you make are **greatly appreciated**.
44

55
## How to Contribute
66

@@ -9,7 +9,7 @@ There are many ways you can contribute to our project:
99
- Submitting bug reports and feature requests
1010
- Writing tutorials or blog posts
1111
- Improving the documentation
12-
- Writing code which can be incorporated into MyPackage itself
12+
- Writing code which can be incorporated into the Timers package itself
1313

1414
### Reporting Bugs
1515

@@ -30,7 +30,7 @@ Here's how you can make a pull request (PR) to the project:
3030

3131
## Coding Guidelines
3232

33-
MyPackage follows the [Microsoft C# Coding Conventions](https://docs.microsoft.com/en-us/dotnet/csharp/fundamentals/coding-style/coding-conventions). Please ensure your code contributions adhere to these standards.
33+
The Timers package follows the [Microsoft C# Coding Conventions](https://docs.microsoft.com/en-us/dotnet/csharp/fundamentals/coding-style/coding-conventions). Please ensure your code contributions adhere to these standards.
3434

3535
## Local Development
3636

@@ -43,10 +43,10 @@ Respect our code of conduct, be kind to each other, and help out with the projec
4343

4444
## License
4545

46-
By contributing to MyPackage, you agree that your contributions will be licensed under MIT.
46+
By contributing to the Timers package, you agree that your contributions will be licensed under MIT.
4747

4848
## Questions?
4949

5050
If you have any questions, please feel free to contact paul@nonatomic.co.uk
5151

52-
Thank you for contributing to MyPackage.
52+
Thank you for contributing to the Timers package.

CONTRIBUTING.md.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Editor.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Editor/com.nonatomic.mypackage.editor.asmdef renamed to Editor/com.nonatomic.timers.editor.asmdef

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2-
"name": "com.nonatomic.mypackage.editor",
3-
"rootNamespace": "Nonatomic.MyPackage",
2+
"name": "com.nonatomic.timers.editor",
3+
"rootNamespace": "",
44
"references": [
5-
"com.nonatomic.mypackage.runtime"
5+
"com.nonatomic.timers.runtime"
66
],
77
"includePlatforms": [
88
"Editor"

Editor/com.nonatomic.mypackage.editor.asmdef.meta renamed to Editor/com.nonatomic.timers.editor.asmdef.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

LICENSE.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 30 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,40 @@
1-
# MyPackage #
1+
# Timers #
22

33
## Overview ##
4-
MyPackage is a Unity package designed to ...
4+
Timer is a versatile, easy-to-use timer component designed for Unity projects. It supports basic timing operations like start, stop, and reset, along with advanced features such as pausing, resuming, fast forwarding, rewinding, and handling milestones that trigger custom actions.
5+
6+
### Features
7+
- Basic Timer Operations: Start, stop, and reset the timer.
8+
- Pause and Resume: Pause the timer and resume from the last stopped point without resetting.
9+
- Fast Forward and Rewind: Jump forward or backward in time.
10+
- **Milestones:** Set up callbacks to execute when the timer reaches certain points.
11+
- **Serialization:** Serialize and deserialize the timer's state, useful for game saves.
12+
- **Extensible:** Easy to extend with additional features and integrate into larger systems.
513

614
## Installation ##
7-
To install MyPackage in your Unity project, add the package from the git URL: https://github.com/PaulNonatomic/MyPackage.git using the Unity package manager.
15+
To install the Timers package in your Unity project, follow these steps:
16+
17+
1. Open Unity and navigate to the Package Manager.
18+
- Click on the + button and select Add package from git URL...
19+
- Enter the following URL: https://github.com/PaulNonatomic/Timer and press Add.
20+
2. Add the Timer component onto any active GameObject in your scene, or create a new GameObject dedicated to the timer.
21+
22+
## Usage ##
823

9-
## Usage ##
10-
...
24+
## API Reference ##
25+
* StartTimer(): Start or restart the timer.
26+
* StopTimer(): Pause the timer.
27+
* ResetTimer(): Reset the timer to its initial state.
28+
* ResumeTimer(): Resume the timer from the last paused state.
29+
* FastForward(float seconds): Advance the timer by a specified number of seconds.
30+
* Rewind(float seconds): Reverse the timer by a specified number of seconds.
31+
* AddMilestone(TimerMilestone milestone): Add a milestone that triggers a callback when reached.
32+
* RemoveMilestone(TimerMilestone milestone): Remove a milestone from the timer.
33+
* ClearMilestones(): Clears all milestones from the timer, ceasing any pending triggers.
34+
* RemoveMilestonesByCondition(Predicate<TimerMilestone> condition): Removes a specific milestone from the timer.
1135

1236
## Contributing ##
1337
Contributions are welcome! Please refer to CONTRIBUTING.md for guidelines on how to contribute.
1438

1539
## License ##
16-
MyPackage is licensed under the MIT license. See LICENSE for more details.
40+
The Timers package is licensed under the MIT license. See LICENSE for more details.

README.md.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)