[release]
[h2]Simple Addon Framework[/h2]
Simple Addon Framework (SAF for short) is a lightweight base for creating small addons with (addons that only need to be ran at start-time (e.g. tips, addons with hooks, etc))
For example, if you wanted to send a message to everybody when someone is killed, you’d have to make a new folder structure (lua/autorun/) to get your addon to run. Simple Addon Framework does that for you.
There is one folder called saf_addons in which you drag all your LUA files to. Then, you simply create functions as if they were hooks (e.g. ADDON:PlayerDeath() or ADDON:PlayerSpawn()), and they will be called as functions rather than using hook.Add.
[h2]Advantages[/h2]
[ul]
[li]Easy to set up, just drag into your addons folder.[/li][li]You don’t need to use hook.Add every time[/li][li]Allows addons to be enabled and disabled at run-time.[/li][li]Is ran on the server and client, so it’s easy for HUD’s, etc[/li][li]Super lightweight and easy to edit - I’ve commented most of it[/li][/ul]
[h2]Documentation[/h2]
I have created a small guide on how to successfully create an addon with SAF:
[ul]
[li]XPS Format: click here[/li][li]PDF Format: click here[/li][/ul]
NOTE: the function RegisterAddon should be AddAddon. sorry for the confusion!
[h2]Download[/h2]
You can download Version 1, here:
[ul]
[li]Non Adf.ly[/li][li]Adf.ly[/li][/ul]
[h2]Media[/h2]
http://connorhaigh.com/files/saf/SAF%20picture%201.JPG
SAF being loaded on a server
http://connorhaigh.com/files/saf/SAF%20picture%202.JPG
SAF loading all addons on startup
[h2]Thanks to[/h2]
[ul]
[li]Overv, for helping me with overriding hook.Call[/li][/ul]
Enjoy!
[/release]