Settings API (load/save data to INI files)
2 Attachment(s)
Settings API
API to load/save settings in a Key+Value format that resembles Windows INI files (http://en.wikipedia.org/wiki/INI_file). What's new is you can store a variable amount of values in a single key, supporting the use of amxx dyamic arrays. Use Case: You want your plugin to use custom sounds and models, then allow users to change them. Previously it would require coding a section into the .sma file, making recompile necessary every time you want to change something. This API allows resources to be edited "externally" through the INI file instead. Example: Load admin knife models from file, store them in dynamic array. If section/key is not found, a new entry will be added automatically. Code:
Code:
; Add custom admin models here Download files below into your scripting folder, then do: #include <amx_settings_api>. |
Re: Settings API (load/save data to INI files)
Awesome, finally you released it. :bee:
|
Re: Settings API (load/save data to INI files)
What's the difference between using "txt" files and "ini" files? Or "cfgs", and others? I don't really know
This would be good as a 3rd party module, for avoiding usage |
Re: Settings API (load/save data to INI files)
I think I will try to import TextParser from SourceMod. It supports INI and Json format. An unified API would be welcomed.
|
Re: Settings API (load/save data to INI files)
I guess I really don't understand the purpose. It appears to me that it's just a global .ini file that can be used by several plugins at once instead of each plugin using it's own.
Quote:
|
Re: Settings API (load/save data to INI files)
Quote:
Quote:
Quote:
|
Re: Settings API (load/save data to INI files)
MeRcyLeZZ, Thanks man it's awesome, but one question ZP4.3fix5a is using this method for saving loading ?
I think i will go back from ZP5.0.8 to 4.3Fix5a but not shure, just asked :) |
Re: Settings API (load/save data to INI files)
Quote:
|
Re: Settings API (load/save data to INI files)
Quote:
|
Re: Settings API (load/save data to INI files)
Quote:
|
All times are GMT -4. The time now is 03:15. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.