https://github.com/subject-team/slib
Subject Library: Useful Codes For GDScript, Improve your code with best ready-made functions!
https://github.com/subject-team/slib
gdscript godot godot-engine godot4 godotengine library plugin
Last synced: 8 months ago
JSON representation
Subject Library: Useful Codes For GDScript, Improve your code with best ready-made functions!
- Host: GitHub
- URL: https://github.com/subject-team/slib
- Owner: Subject-Team
- License: mit
- Created: 2024-08-16T07:03:10.000Z (almost 2 years ago)
- Default Branch: Main
- Last Pushed: 2025-02-07T14:36:12.000Z (over 1 year ago)
- Last Synced: 2025-02-07T15:22:21.701Z (over 1 year ago)
- Topics: gdscript, godot, godot-engine, godot4, godotengine, library, plugin
- Language: GDScript
- Homepage: https://subject-team.github.io/SLib/
- Size: 1.51 MB
- Stars: 12
- Watchers: 1
- Forks: 1
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
README
# Subject-Library
Useful Codes For GDScript

















## The fastest answer to the question "What is SLib?"
SLib is a versatile library whose functions are used in any project, SLib improves code quality several times, increases its readability, prevents errors, and thus makes your project better and faster than before! The following code is just one of the things that SLib does:
### With SLib:
```gdscript
# This one line of code creates a backup of the player's data file with an optional
# extension next to it, it has the ability to check all types of errors and manage them,
# prevent syntax errors, repeating lines and code length.
SLib.backup_file("user://main_data.json")
```
### Without SLib:
```gdscript
# These 10 lines of code do the same thing as one line above, with the difference that
# the file extension and path must be specified in several places each time.
# and creates variables that are no longer usable!
var file_access := FileAccess.open("user://main_data.json", FileAccess.READ)
var json_string := file_access.get_line()
file_access.close()
var json := JSON.new()
json.parse(json_string)
var data = json.data
var backup_json_string := JSON.stringify(data)
var backup_file_access := FileAccess.open("user://main_data.json".get_basename() + "-Backup." +"user://main_data.json".get_extension(), FileAccess.WRITE)
backup_file_access.store_var(backup_json_string)
backup_file_access.close()
```
## [Overview](https://github.com/Subject-Team/SLib#overview)
SLib is a Godot library designed to simplify and enhance your development experience. It provides a set of ready-to-use, standard codes that eliminate the need to write repetitive and lengthy scripts. SLib is lightweight, easy to install, and helps make your code more readable and maintainable.
## [Fast Getting Started](https://github.com/Subject-Team/SLib/wiki#fast-getting-started) & [Defalut Getting Started](https://github.com/Subject-Team/SLib/wiki#default-getting-started)
## They use SLib
### [Text Forge](https://github.com/mkh-user/Text-Forge)
Open source, lightweight, and highly modular code editor
## Click on the desired topic:
### [Fast Getting Started](https://github.com/Subject-Team/SLib/wiki#fast-getting-started)
Let's Install!
### [Why use?](https://github.com/Subject-Team/SLib/wiki/Why-use%3F)
How does SLib help you?
### [Key Features](https://github.com/Subject-Team/SLib/wiki/Key-Features)
Why is SLib a powerful and useful library?
### [Versions](https://github.com/Subject-Team/SLib/wiki/Versions)
Browse available versions
### [Change Logs](https://github.com/Subject-Team/SLib/wiki/Change-Logs)
View the project development process
### [Supported Versions](https://github.com/Subject-Team/SLib/wiki/Supported-Versions)
In which version of Godot can I use SLib?
### [How To Install](https://github.com/Subject-Team/SLib/wiki/Installation-guid)
Install SLib on your project
### [Automation](https://github.com/Subject-Team/SLib/wiki/Automation)
Convert simple texts into complex codes
### [How To Use](https://github.com/Subject-Team/SLib/wiki/Learn-how-to-use-SLib)
Upgrade your code with SLib
### [Detailed capabilities](https://github.com/Subject-Team/SLib/wiki/Detailed-capabilities)
Learn the details of SLib's capabilities
### [Bug fix guid](https://github.com/Subject-Team/SLib/wiki/Bug-fix-guide)
How to correct errors?
### [Community and Support](https://github.com/Subject-Team/SLib/wiki/Community-and-Support)
Join the SLib community and get help from each other
### [Documentation](https://github.com/Subject-Team/SLib/wiki/Documentation)
Documentation and user guide
### [Contribute](https://github.com/Subject-Team/SLib/wiki/Types-of-contributions)
This is an open source project, we grow together!
### [Thanks](https://github.com/Subject-Team/SLib/wiki/Thanks)
Project participation process and contributors
---
### Feel free to ask questions, give ideas, and contribute in discussions and issues!