View Single Post
  #1  
Unread 10-02-2011, 01:19 AM
MrJackdaw's Avatar
MrJackdaw MrJackdaw is offline
The Undying
Interface Author - Click to view interfaces
 
Join Date: Feb 2009
Location: Lancaster, England
Posts: 249
New Warden functions

I managed to access the new warden functions yesterday and thought it may be useful to show the code here;

First, set the player and playerattributes;
Code:
Player = Turbine.Gameplay.LocalPlayer.GetInstance()
PlayerAttributes=Player:GetClassAttributes()
Then the listener;
Code:
PlayerAttributes.GambitChanged=function()  
*What you want to happen*
end
PlayerAttributes:GetGambitCount() returns the count of current gambits
PlayerAttributes:GetGambit(i) returns which gambit (fist,shield,spear) is in slot i
PlayerAttributes:GetGambit(PlayerAttributes:GetGam bitCount()) returns the last used gambit - will throw an error if it is zero.

Have fun!
__________________
************************************************** ************************************************** **
"Our ideals may never be realised, But they indicate what we are trying to do." Dick Tahta
Reply With Quote