Quantcast ouf classic - classpower error - WoWInterface
Thread Tools Display Modes
10-30-19, 12:53 AM   #1
10leej
A Molten Giant
 
10leej's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2011
Posts: 579
ouf classic - classpower error

Originally Posted by zork View Post
Tukz has a fork of his UI for classic inluding the oUF lib modified for classic:
https://git.tukui.org/Tukz/Tukui/tre...Tukui/Libs/oUF

The commit history can be seen here:
https://git.tukui.org/Tukz/Tukui/com...Tukui/Libs/oUF
(just quoting zork from a different thread here so we can cite our sources)

Not sure if it's because of how I'm calling it, but classpower.lua is posting this error. Been a minute since I even worked on lua so maybe I'm being stupid like I always seem to be when posting stuff here

Code:
1x oUF\elements\classpower.lua:169: attempt to call global 'UnitHasVehicleUI' (a nil value)
oUF\elements\classpower.lua:169: in function <oUF\elements\classpower.lua:165>
(tail call): ?
oUF\ouf-9.1.3.lua:211: in function <oUF\ouf.lua:194>
(tail call): ?

Locals:
self = oUF_BobPlayer {
 0 = <userdata>
 UNIT_PORTRAIT_UPDATE = <function> defined @oUF\elements\portrait.lua:87
 HealthPrediction = <table> {
 }
 __tags = <table> {
 }
 UNIT_MAXPOWER = <function> defined @oUF\elements\power.lua:247
 UNIT_SPELLCAST_CHANNEL_START = <function> defined @oUF\elements\castbar.lua:270
 unitEvents = <table> {
 }
 UNIT_HEALTH_FREQUENT = <function> defined @oUF\elements\health.lua:179
 PORTRAITS_UPDATED = <function> defined @oUF\elements\portrait.lua:87
 __elements = <table> {
 }
 UNIT_POWER_FREQUENT = <function> defined @oUF\elements\power.lua:247
 Power = <unnamed> {
 }
 UNIT_POWER_BAR_SHOW = <function> defined @oUF\elements\power.lua:247
 style = "Bob"
 RAID_TARGET_UPDATE = <function> defined @oUF\elements\raidtargetindicator.lua:62
 UNIT_CONNECTION = <table> {
 }
 Portrait = <unnamed> {
 }
 UNIT_SPELLCAST_START = <function> defined @oUF\elements\castbar.lua:107
 unit = "player"
 UNIT_SPELLCAST_DELAYED = <function> defined @oUF\elements\castbar.lua:221
 UNIT_SPELLCAST_STOP = <function> defined @oUF\elements\castbar.lua:248
 UNIT_SPELLCAST_CHANNEL_STOP = <function> defined @oUF\elements\castbar.lua:364
 UNIT_SPELLCAST_CHANNEL_UPDATE = <function> defined @oUF\elements\castbar.lua:334
 UNIT_SPELLCAST_INTERRUPTED = <function> defined @oUF\elements\castbar.lua:193
 AdditionalPower = <unnamed> {
 }
 PLAYER_ENTERING_WORLD = <function> defined @oUF\ouf.lua:194
 RaidTargetIndicator = <unnamed> {
 }
 UNIT_SPELLCAST_FAILED = <function> defined @oUF\elements\castbar.lua:165
 UNIT_FACTION = <table> {
 }
 ResurrectIcon = <unnamed> {
 }
 UNIT_MAXHEALTH = <function> defined @oUF\elements\health.lua:179
 UNIT_DISPLAYPOWER = <function> defined @oUF\elements\power.lua:247
 UNIT_FLAGS = <table> {
 }
 Castbar = <unnamed> {
 }
 UNIT_POWER_BAR_HIDE = <function> defined @oUF\elements\power.lua:247
 ClassPower = <table> {
 }
 Health = <unnamed> {
 }
 UNIT_MODEL_CHANGED = <function> defined @oUF\elements\portrait.lua:87
}
event = "PLAYER_ENTERING_WORLD"
unit = "player"
element = <table> {
 1 = <unnamed> {
 }
 2 = <unnamed> {
 }
 3 = <unnamed> {
 }
 4 = <unnamed> {
 }
 5 = <unnamed> {
 }
 6 = <unnamed> {
 }
 7 = <unnamed> {
 }
 8 = <unnamed> {
 }
 9 = <unnamed> {
 }
 10 = <unnamed> {
 }
 11 = <unnamed> {
 }
 __owner = oUF_BobPlayer {
 }
 ClassPowerEnable = <function> defined @oUF\elements\classpower.lua:225
 ForceUpdate = <function> defined @oUF\elements\classpower.lua:220
 PostUpdate = <function> defined @oUF_Bob\modules\units.lua:25
 ClassPowerDisable = <function> defined @oUF\elements\classpower.lua:238
 UpdateColor = <function> defined @oUF_Bob\modules\units.lua:54
 __max = 11
}
shouldEnable = nil
(*temporary) = nil
(*temporary) = "player"
(*temporary) = "attempt to call global 'UnitHasVehicleUI' (a nil value)"
ClassPowerID = nil
RequireSpec = nil
RequirePower = nil
RequireSpell = nil
Visibility = <function> defined @oUF\elements\classpower.lua:165
ClassPowerType = nil
UpdateColor = <function> defined @oUF\elements\classpower.lua:69
ClassPowerEnable = <function> defined @oUF\elements\classpower.lua:225
ClassPowerDisable = <function> defined @oUF\elements\classpower.lua:238
Path = <function> defined @oUF\elements\classpower.lua:153
my code is here

Seems like Tukz cut classpower.lua altogether along with a few others

I found just commenting out lines 169-172 fixes the error at least, I haven't really tested it though. I'm debating if it's just simpler just to "borrow" Tukz ouf altogether rather than see how far I can get the official version working.

But on the bright side, I have oUF_Bob mostly functional on wow classic. My next goal is to make some functional nameplates, but of course I haven't actually found some good examples of it that I can wrap my little head around.
__________________
Tweets Facebook YouTube Website

Last edited by 10leej : 10-30-19 at 04:41 AM.
  Reply With Quote
11-04-19, 12:45 PM   #2
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
Featured
Join Date: Oct 2006
Posts: 10,674
Vehicles and the vehicle API don't exist in classic.
__________________
"You'd be surprised how many people violate this simple principle every day of their lives and try to fit square pegs into round holes, ignoring the clear reality that Things Are As They Are." -Benjamin Hoff, The Tao of Pooh

  Reply With Quote
11-08-19, 09:40 AM   #3
10leej
A Molten Giant
 
10leej's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2011
Posts: 579
Originally Posted by Seerah View Post
Vehicles and the vehicle API don't exist in classic.
0.0 silly me, that's what I get for being a wrath baby.
__________________
Tweets Facebook YouTube Website
  Reply With Quote

WoWInterface » Featured Projects » oUF (Otravi Unit Frames) » ouf classic - classpower error

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off