Slashing Ability Key Bindings

by Talnar

Back to Mechanic's Corner.

Talnar2007-07-12 02:22:02
I set up the Number Pad keys to do the strikes in the Slashing ability in Knighthood. First, I set up an alias to do one of the strikes, then put a Key Binding up to execute that alias. For example:

CODE
Alias
Name: hackdown
Script: hack down &target

Keybinding
Name: Ctrl + NumPad-8
Script: hackdown


I really don't see a problem, but then again, I'm still a noob when it comes to scripting. Any help?
Xavius2007-07-12 02:26:49
QUOTE(Talnar @ Jul 11 2007, 09:22 PM) 424898
I set up the Number Pad keys to do the strikes in the Slashing ability in Knighthood. First, I set up an alias to do one of the strikes, then put a Key Binding up to execute that alias. For example:

CODE
Alias
Name: hackdown
Script: hack down &target

Keybinding
Name: Ctrl + NumPad-8
Script: hackdown


I really don't see a problem, but then again, I'm still a noob when it comes to scripting. Any help?


This is Nexus, right?

Potential Obvious Issue #1: Check NumLock.
Potential Obvious Issue #2: Unsupported keystroke. Bind it to "giggle" or something to test.

Less Obvious Issue: I'm not entirely sure that Nexus supports aliases in keybindings.
Talnar2007-07-12 02:34:26
QUOTE(Xavius @ Jul 12 2007, 02:26 AM) 424900
Less Obvious Issue: I'm not entirely sure that Nexus supports aliases in keybindings.


It does. My main hunting alias is 'attack', and it works fine. I set that to the F1 key, though, if that helps...

Also, originally I had the Keybinding script set as: hack down &target, and I'd just do: ST TARGET to get the target variable.
Hazar2007-07-12 02:42:24
I'd reccomend setting a variable at the beginning of the alias so it supports slashes, strikes, and lunges.
Talnar2007-07-12 02:53:44
Erm... How? Remember, I'm a noob at scripting! tongue.gif
Hazar2007-07-12 03:44:07
Erm...not quite sure about the specifics of nexus...

Set a variable: padmode.

Then have three aliases for changing it: swingmode, strikemode, lungemode.

Each sets padmode to a different value: 1, 2, or 3.

Then...each keybinding starts with an if/then statement.

IF padmode=1 THEN swing down $target
IF padmode=2 THEN strike head $target
IF padmode=3 THEN lunge head $target