Mercurial > wow > cyborg-mmo7
comparison WowObjects.lua @ 14:9f2d838d4f8e
Added some missing local variable declarations, and other unwanted global accesses.
author | madcatzinc@35b17cf1-18cd-47ff-9ca3-31d6b526ef09 |
---|---|
date | Thu, 25 Apr 2013 01:29:50 +0000 |
parents | 6cb9a2936580 |
children | 80192bc4a108 |
comparison
equal
deleted
inserted
replaced
13:6cb9a2936580 | 14:9f2d838d4f8e |
---|---|
57 DoNothing = function() | 57 DoNothing = function() |
58 end, | 58 end, |
59 | 59 |
60 Load = function(object) | 60 Load = function(object) |
61 if type == "item" then | 61 if type == "item" then |
62 object = CyborgMMO_WowItem.Load(Object) | 62 object = CyborgMMO_WowItem.Load(object) |
63 elseif type == "macro" then | 63 elseif type == "macro" then |
64 object = CyborgMMO_WowMacro.Load(object) | 64 object = CyborgMMO_WowMacro.Load(object) |
65 elseif type == "spell" then | 65 elseif type == "spell" then |
66 object = CyborgMMO_WowSpell.Load(object) | 66 object = CyborgMMO_WowSpell.Load(object) |
67 elseif type == "petaction" then | 67 elseif type == "petaction" then |
71 elseif type == "companion" then | 71 elseif type == "companion" then |
72 object = CyborgMMO_WowCompanion.Load(object) | 72 object = CyborgMMO_WowCompanion.Load(object) |
73 elseif type == "equipmentset" then | 73 elseif type == "equipmentset" then |
74 object = CyborgMMO_WowEquipmentSet.Load(object) | 74 object = CyborgMMO_WowEquipmentSet.Load(object) |
75 else | 75 else |
76 object = CyborgMMO_WowObject.new(type, detail, subdetail) | 76 object = CyborgMMO_WowObject.new(type, nil, nil) |
77 end | 77 end |
78 return object | 78 return object |
79 end, | 79 end, |
80 | 80 |
81 -- Static Methods -- | 81 -- Static Methods -- |
400 -- WowEquipmentSet Class -- | 400 -- WowEquipmentSet Class -- |
401 CyborgMMO_WowEquipmentSet = { | 401 CyborgMMO_WowEquipmentSet = { |
402 new = function(objectType, name, index) | 402 new = function(objectType, name, index) |
403 local self = CyborgMMO_WowObject.new(objectType, name, index) -- base class | 403 local self = CyborgMMO_WowObject.new(objectType, name, index) -- base class |
404 -- Set all the item info. -- | 404 -- Set all the item info. -- |
405 texture,lessIndex = GetEquipmentSetInfoByName(name) | 405 local texture,lessIndex = GetEquipmentSetInfoByName(name) |
406 self.Texture = "Interface\\Icons\\"..texture | 406 self.Texture = "Interface\\Icons\\"..texture |
407 self.Name = name | 407 self.Name = name |
408 self.Index = lessIndex + 1 | 408 self.Index = lessIndex + 1 |
409 | 409 |
410 -- override method -- | 410 -- override method -- |