土豆兄弟(Brotato)

土豆兄弟(Brotato)

评价数不足
Builder Template v1.2.0
   
奖励
收藏
已收藏
取消收藏
文件大小
发表于
更新日期
14.933 KB
2024 年 12 月 23 日 上午 1:31
2024 年 12 月 30 日 上午 4:14
5 项改动说明 ( 查看 )

订阅以下载
Builder Template v1.2.0

描述



Builder Template
Setup your plugin optimized and with ease!

Building plugins has never been easier with The Builder Template. This plugin offers a fast and efficient way to set up new projects. It streamlines the code, provides pre-made utilities, and ensures minimal effort when configuring your plugin. The code is designed to be as minimalist as possible, avoiding unnecessary copying and pasting to prevent lag in the game. The Builder Template delivers the most optimized approach for initializing your plugin.

Ever wanted to make a plugin for Brotato, but never got to it cause you never could figure out how it all works? Did you got overwelmed by everything that needs to be done, before you can run your first test, thus preventing you getting it to work? Well that is now history!




Work In Progress!!
Building, Building, Building!

You can now use the Builder Template to create your plugins, and everything built within it is functioning well. The Builder Template is the result of rebuilding my BroCore (link) plugin for Brotato. During this process, I realized the amount of work required to not only get a plugin running error-free but also to optimize it without redundant code.

I also recognized that many non-developers can understand and manipulate code to create simple plugins. However, they might need some extra help if they want to learn to implement more advanced features, such as lag reduction, or loading and saving configuration variables and session data, or even persisting data between games.

As I continue to rebuild BroCore and design a better system for it, I’m sharing the core code used by BroCore for you to use. So keep in mind that more might be added in the future.




Support!
Do you like my work? Please consider giving this plugin
a thumbsup on the Steam Workshop, this help a lot.






Documentation!
Knowledge defeats ignorance!

As I have just created this plugin, there is no documentation yet. However, I’ve included an Instructions file within the plugin with some explanations on what you need to do for setup, as well as details about the functions, files, and code blocks. While this doesn’t yet provide full information on everything available, I will be adding more soon.

Once I have more time, I’ll create proper documentation for you to read.




Dynamic Code!
Sometimes repetition is a bad thing!

What causes games to lag? Large code blocks, especially when code is copied and pasted, can significantly impact performance. This increases the amount of code that needs to be compiled when the game starts, which in turn increases the load time. Some files are executed in full each time they are called, meaning that duplicated code will slow down the game and create lag, especially in higher rounds.

I’ve minimized and compacted the code as much as possible to avoid repetition. Additionally, I’ve made the code modular so it automatically adjusts based on the values you set within the arrays. The only thing you need to modify are the arrays of the template and core variables, such as the plugin name. Other than your custom scripts, nothing else needs to be done to initialize your scripts within the Builder Template.




How to use and start?
Let's set things up shell we!

First we need to fetch the Builder Template files.
  1. Install this plugin so steam downloads it to your game.
  2. Go to where your steam is installed ( Steam Game Folder )
  3. Enter the folder "steamapps"
  4. Enter the folder "workshop"
  5. Enter the folder "content"
  6. Enter the folder "1942280"
  7. Enter the folder "3390064723"

Here you will find the Builder Template plugin. You can open the .ZIP file, then enter the "mods-unpacked" folder. Now you see the folder "DevDokus-BuilderTemplate". Copy this folder to your GoDot game engine within the mods-unpacked folder. Now you can start coding.

Note:
  • Make sure to edit the manifest data.
  • Make sure to edit the variables within mod_main.gd
  • Make sure to edit the variables within Options.gd
  • Rename the menu variable within Menu.gd

Changing the menu variable is important! As this gets loaded with ModOptions, and it does not allow 2 plugins to have the same variable for this menu, thus it can conflict with other plugins. So make sure to change this.




Last Words

I hope you all have lots of fun creating your plugins! Just keep in mind that this project will get expanded over time as I am developing on BroCore. Let me know what you think of this template, and if you like it give me a thumbsup! It really helps a lot :)

BroCore
https://psteamcommunity.yuanyoumao.com/sharedfiles/filedetails/?id=3382774065
1 条留言
1422351061 1 月 25 日 上午 6:09 
生成器模板