Hello everyone!
I made a library that i think(hope) could interest some of you:
-Core:
-Debug log functions with log levels, buffer, log table as well, including self-referencing ones
-Routines that doubles as timers
-Ability to save/load data between games - requires the user to unzip the mod and launch a script (linux and windows)
-UI templating and automation
-Write a template and don't bother manually creating/destroying elements
-Auto-save values (checkbox, etc)
-Widgets... well combo box and list
-Astar pathfinding
-Uses routine to work in background
-Diagonal or grid-based
-Intervalled path for electric poles or roboports
-various other options
-Map - not ready yet
-Auto detect outposts and their contour
-Auto detect resources
-Neural network - not ready yet
-Not using routine yet
-Uses sigmoid function
-I tried to add other activation functions and adaptative learning rate algo (momentum) but i'm bad at math if someone knows its stuff, i'm interested
The question is: are you interested and is it worth it that i make proper documentation and all? Any ideas on what should be there?
You can find a previous version in my Exoman mod, still needs a lot of work but constructive criticism is welcome.
Thanks to binbinhfr, killkrog and Choumiko!
Thank you in advance!
Factorio libre: a Factorio mod standard library... maybe?
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
Re: Factorio libre: a Factorio mod standard library... maybe?
Maybe contribute to https://github.com/Afforess/Factorio-Stdlib
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
Re: Factorio libre: a Factorio mod standard library... maybe?
Yes please contribute to Afforess' "Factorio Standard Library" project on Github. We would all welcome your additions in that, to keep everything all together! Some double-up of functionality though, so some parts may need to be left out during integration. Best to get in touch with Afforess in any case, and work it out.
Re: Factorio libre: a Factorio mod standard library... maybe?
Yay, library with functionality!
Advanced stuff like "Astar pathfinding", "UI templating and automation" would be surely of use. Not everytime, but whenever there's need for them, these functions will be a huge boon. Someday I might even use the library with those.
And documentation is never bad.
Also, assuming by routines you mean those from `coroutine` library, have you tested them against save-loading process? Factorio doesn't save any metadata, so I'm not sure, but I'd expect problems from the coroutines.
Advanced stuff like "Astar pathfinding", "UI templating and automation" would be surely of use. Not everytime, but whenever there's need for them, these functions will be a huge boon. Someday I might even use the library with those.
And documentation is never bad.
Also, assuming by routines you mean those from `coroutine` library, have you tested them against save-loading process? Factorio doesn't save any metadata, so I'm not sure, but I'd expect problems from the coroutines.
I do mods. Modding wiki is friend, it teaches how to mod. Api docs is friend too...
I also update mods, some of them even work.
Recently I did a mod tutorial.
I also update mods, some of them even work.
Recently I did a mod tutorial.
Re: Factorio libre: a Factorio mod standard library... maybe?
The routines part a simple function which catch the on_tick event that iterate through an array of functions. I haven't tried lua coroutines, i doubt it's possible, Factorio being a custom lua Vm and mods being mono-thread.Adil wrote:Yay, library with functionality!
Advanced stuff like "Astar pathfinding", "UI templating and automation" would be surely of use. Not everytime, but whenever there's need for them, these functions will be a huge boon. Someday I might even use the library with those.
And documentation is never bad.
Also, assuming by routines you mean those from `coroutine` library, have you tested them against save-loading process? Factorio doesn't save any metadata, so I'm not sure, but I'd expect problems from the coroutines.
Thanks for the input!
Re: Factorio libre: a Factorio mod standard library... maybe?
I have A* pathfinding already written for Factorio, for the Misanthrope mod, but I have never had enough interested modders to try porting it to a more standard 'library' module. The main issue is that A* in Lua is painfully slow, so unless your paths are fairly short, its not useful.Adil wrote:Yay, library with functionality!
Advanced stuff like "Astar pathfinding", "UI templating and automation" would be surely of use. Not everytime, but whenever there's need for them, these functions will be a huge boon. Someday I might even use the library with those.
And documentation is never bad.
Also, assuming by routines you mean those from `coroutine` library, have you tested them against save-loading process? Factorio doesn't save any metadata, so I'm not sure, but I'd expect problems from the coroutines.
@sebgggg if you're serious about wanting to contribute (or make your own library), should make sure you look at documentation and unit testing. I am using the busted framework for testing and ldoc to make pretty web documentation. For a good code library to succeed, its not enough to have working code. I have put a fair amount of effort into ensuring every release of the factorio standard library is backwards compatible, fully tested, and compatible even between factorio versions (it works between 13.x and 14.x).
I think anything you can contribute to the factorio standard library would be awesome, but I fully understand if you want to strike out on your own.
Re: Factorio libre: a Factorio mod standard library... maybe?
I like this! Would using hardlinks work in place of the symlink? Hardlinks don't require admin privs on winblows-Ability to save/load data between games - requires the user to unzip the mod and launch a script (linux and windows)
Re: Factorio libre: a Factorio mod standard library... maybe?
Yes it does! I assumed it required admin rights as well! Thanks!Nexela wrote:I like this! Would using hardlinks work in place of the symlink? Hardlinks don't require admin privs on winblows-Ability to save/load data between games - requires the user to unzip the mod and launch a script (linux and windows)