Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
LoTekkie committed Mar 16, 2019
2 parents 039de88 + f498f06 commit 81c0681
Show file tree
Hide file tree
Showing 9 changed files with 34 additions and 820 deletions.
24 changes: 13 additions & 11 deletions Clutch.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,15 @@ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
]]

local LSC = LibStub("LibSlashCommander")
]]--

if Clutch == nil then Clutch = {} end

Clutch.name = "Clutch"
Clutch.version = "0.9.0"
Clutch.version = "0.9.1"
Clutch.author = "Sjshovan (Apogee)"
Clutch.contact = "Sjshovan@Gmail.com"
Clutch.url_readme = "https://github.com/Ap0gee/Clutch"
Clutch.description = "Clutch aims to prevent weapons from falling to the ground and grants the ability to pick them back up if they do."
Clutch.commands = {"/clutch", "/clch"}

Expand Down Expand Up @@ -61,14 +60,14 @@ local function buildHelpEntryCommand(command, description)
local addon_name = cStr(Clutch.colors.primary, "/"..string.lower(Clutch.name))
local command = cStr(Clutch.colors.info, command)
local description = cStr(Clutch.colors.info, description)
local sep = cStr(Clutch.colors.primary, "=>")
local sep = cStr(Clutch.colors.secondary, "=>")
return string.format("%s %s %s %s", addon_name, command, sep, description)
end

local function buildHelpEntry(key, value)
local key = cStr(Clutch.colors.info, key)
local key = cStr(Clutch.colors.primary, key)
local value = cStr(Clutch.colors.info, value)
local sep = cStr(Clutch.colors.primary, "=>")
local sep = cStr(Clutch.colors.secondary, "=>")
return string.format("%s %s %s", key, sep, value)
end

Expand Down Expand Up @@ -121,8 +120,8 @@ function Clutch.onPlayerActivated()
cStr(Clutch.colors.primary, Clutch.author)
))
Clutch.startup_info_displayed = true
end
end

Clutch.clutchWeapons()
end

Expand All @@ -148,7 +147,9 @@ function Clutch.onAddonLoaded(eventCode, addonName)

ZO_CreateStringId("SI_BINDING_NAME_CLUTCH_WEAPONS", "Clutch Weapons")

LSC:Register(Clutch.commands, function(...) Clutch.onCommandEntered(...) end, "Invoke the Clutch addon")
for index, command in pairs(Clutch.commands) do
SLASH_COMMANDS[command] = Clutch.onCommandEntered
end

Clutch.help = {
commands = {
Expand All @@ -168,11 +169,12 @@ function Clutch.onAddonLoaded(eventCode, addonName)
buildHelpEntry("Description", Clutch.description),
buildHelpEntry("Author", Clutch.author),
buildHelpEntry("Contact", Clutch.contact),
buildHelpEntry("README", Clutch.url_readme),
buildHelpEntry("Version", Clutch.version),
buildHelpSeperator('=', 14),
}
}

EVENT_MANAGER:RegisterForEvent(Clutch.name, EVENT_PLAYER_ACTIVATED, Clutch.onPlayerActivated)
end

Expand Down
9 changes: 2 additions & 7 deletions Clutch.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@
## Description: Clutch aims to prevent weapons from falling to the ground and grants the ability to pick them back up if they do.
## APIVersion: 100026
## Author: |c9ab3e5Sjshovan (Apogee)|r
## Version: 0.9.0
## OptionalDependsOn: LibStub LibSlashCommander

lib/LibStub/LibStub.lua
lib/LibSlashCommander/LibSlashCommander.lua
lib/LibSlashCommander/descriptions/$(language).lua
## Version: 0.9.1

Clutch.lua
bindings.xml
bindings.xml
34 changes: 19 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
**Author:** [Sjshovan (Apogee)](https://github.com/Ap0gee)
**Version:** v0.9.0
**Version:** v0.9.1


# Clutch
Expand Down Expand Up @@ -40,7 +40,7 @@ ___
2. Click on `Releases`.
3. Click on the `Source code (zip)` link within the latest release to download.
4. Extract the zipped folder to `.../Documents/Elder Scrolls Online/live/AddOns`.
5. Rename the folder to remove the version tag (`-v0.9.0`). The folder should be named `Clutch`.
5. Rename the folder to remove the version tag (`-v0.9.1`). The folder should be named `Clutch`.

**Manual (From ESOUI):**
1. Navigate to <https://www.esoui.com/addons.php>.
Expand Down Expand Up @@ -77,39 +77,39 @@ Invoke the Clutch addon with the following commands:

/clutch
/clch
___
### Commands

**help**

Displays the available Clutch commands. Below are the equivalent ways of calling the command:
/clutch help
/clch help
/clutch h
/clch h
/clutch h
/clch h
**activate**

Manually activates Clutch and picks up your weapons. Below are the equivalent ways of calling the command:
/clutch activate
/clch activate
/clutch a
/clutch a
/clch a

**info**

Display information about Clutch. Below are the equivalent ways of calling the command:

/clutch info
/clch info
/clch info

/clutch i
/clch i
/clutch i
/clch i

___
### Support
Expand All @@ -128,14 +128,18 @@ ___
___
### Change Log

**v0.9.1** - 3/16/2019
- **Remove:** libStub and LibSlashCommander dependencies removed.
- **Update:** Cli colors changed.
- **Add:** README url added to info display.

**v0.9.0** - 3/15/2019
- Initial release

___
### Known Issues

None

___
### TODOS

Expand Down
15 changes: 0 additions & 15 deletions lib/LibSlashCommander.txt

This file was deleted.

Loading

0 comments on commit 81c0681

Please sign in to comment.