Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
WoW Character BBCode Details »»
WoW Character BBCode
Version: 0.4.9b, by sweede sweede is offline
Developer Last Online: Jun 2014 Show Printable Version Email this Page

Category: Miscellaneous Hacks - Version: 3.7.x Rating:
Released: 02-01-2008 Last Update: 11-24-2008 Installs: 94
DB Changes Uses Plugins Template Edits
Re-useable Code Additional Files Translations Is in Beta Stage  
No support by the author.

This is a continuation of the project, https://vborg.vbsupport.ru/showthread.php?t=160418 . I have made several modifications to the original authors code and several have asked for my modifications.

Because of this and the original authors lack of updating the original modification, I have decided to upload this package for all to use.

All credit goes to the original author(s) of the utility as i have only cleaned up the code and packaged it for easy usage.

WARNING!
This is very beta at this time. I have added the product now to force myself to update and maintain the plugin and to share it with the rest of my fellow World of Warcraft webmasters

Installation
  1. Uninstall your existing WoW Char Code installation. I have changed the product ID itself and it may not update everything correctly.
  2. Remove the clientscript/ajax_tooltip and clientscript/phparmory folders if they exist
  3. Upload the contents of the "Upload" Folder to the ROOT directory of your forums (for example, if you have your forums installed in /home/mydir/public_html/forums , you would unzip into that folder.)
  4. Import the product/product-WoWCharBBCode-?.??.xml file

Changelog
  • 0.4.9b
    • Added basic Death Knight support
    • Fixed problem with characters with no professions (common with Death Knights)
  • 0.4.9a
    • Fixed a minor issue with realms in spaces in the name
  • 0.4.9
    • Added wysiwyg support
  • 0.4.8a
    • Fixed a php parse error in functions_wowcharcode.php. you do not need to download the entire zip file, just replace your existing functions_wowcharcode.php file with the attached .php file
  • 0.4.8
  • 0.4.7a
    • Removed some left over debugging statements and info in the product and php file.
  • 0.4.7
    • Changed the backend armory code.
    • Updated caching to not cache Armory results that end up as errors
    • Added character class, race and professions as vbphrases.
    • Added KR and TW Armory locales. (, etc)
    • Some minor fixes.
  • 0.4.4
    • Added Icon caching to help with slow armory. Images are cached by default in the armory folder. chmod this folder to 777 and icons will be automaticly cached to this folder.
    • You can now use the variable $wowchar_code in the postbit (or postbit_legacy) to display the character tooltip in a post.
  • 0.4.3 Fixed issue with rebuilding post cache.
  • 0.4.2 Added option to show/hide realm if a default realm is set.
  • 0.4.1 Fixed an issue if the character doesnt have armory data, Only change is in functions_wowcharcode.php file.
  • 0.4
    • All Character stat text are now phrases. you will find a new Phrase Type in the Phrase Manager ( WoW BBCode Phrases )
    • Added default realm option so one does not need to use the [char=server] option when specifying characters on own realm.
    • Customized the stat display per class and on some specs (such as feral v.s. resto druids). see an example at http://www.dramaloot.com/forums/showthread.php?p=19271
  • 0.3
    • Armory Caching works for both US and EU armorys.
    • Removed un-used files.
    • Put the majority of the codes HTML creation as templates and use vbulletins ajax.php and hooks.
    • Added options for default locale (armory) to use (currently EU and US armories).
    • Added option to disable caching of the Armory (i use it to test armory retrieval)
    • Added ability to specify what armory the character / realm you would like, see usage notes below.
  • 0.2
    • Armory Caching never actually worked properly, this should now be fixed.
    • Remove the includes/functions_wow3bbcode.php file. This has been replaced by a plugin.
    • Remove the clientscript/phparmory/config.php file. This isnt needed.
    • Major updates to phparmory.php
    • Minor Plugin changes + code cleanup.
ToDo
  • New tooltip javascript
  • New character sheet.
  • Create easy to modify interface for character stats to be displayed in tooltip.


Usage
Using the character code is easy enough,
[char]CHARACTER[/char] if default realm option is set and character links is on same realm.
For characters not on the same realm as the default,
[char=SERVER]CHARACTER[/char]
For example,
[char=Vek'nilash]Azaril[/char]
Or, if you want to link a character profile from another locale (i.e. EU realms) , you simply add EU- before the server name.
[char=EU-Vek'nilash]Azaril[/char]

The same thing applies to linking US realm characters from a EU default forum.

See a working example at http://www.dramaloot.com/index.php?id=officer_cl (This is a vbadvanced custom page using the BBCode page type).

Added German translation for what i currently have localized. Provided by jluerken http://www.wow-relaxed.de

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #62  
Old 02-26-2008, 11:14 AM
sweede's Avatar
sweede sweede is offline
 
Join Date: Jan 2007
Posts: 391
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by hinch View Post
Just installed this and it works great but at the same time throws up some mkdir errors.

Line in question is
PHP Code:
mkdir($full_image_path ,0777,true); 
I've attached a screenshot so you can see the errors its throwing up

Change that line to my post above, ( https://vborg.vbsupport.ru/showpost....5&postcount=56 )
change the
@mkdir($path ,0777,true);
to
@mkdir($path ,0777);

That should fix the problem.
Reply With Quote
  #63  
Old 02-26-2008, 01:12 PM
hinch's Avatar
hinch hinch is offline
 
Join Date: May 2003
Location: UK
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yup appears to have fixed it looking good thanks
Reply With Quote
  #64  
Old 02-26-2008, 01:33 PM
hinch's Avatar
hinch hinch is offline
 
Join Date: May 2003
Location: UK
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I also added this into my postbit but there's a much easier way of doing it than the one listed above.

Create a custom profile field for users called whatever you like in my case i called it wow main char. (field11)

user puts in the name of their wow char there.
Then i just edited the postbit_legacy and added in the following

Code:
<if condition="$post[field11]">
<br />
<strong>WoW Char:</strong> <a style="cursor: pointer;" href="http://eu.wowarmory.com/character-sheet.xml?r=Al%27Akir&amp;n=$post[field11]" target="new" onmouseover="ajax_showTooltip(&quot;http://www.furious-angels.com/ajax.php?do=wowcharcode&server=Al'Akir&char=$post[field11]&quot;,this); return false" onmouseout="ajax_hideTooltip()">$post[field11]</a>
</if>
Reply With Quote
  #65  
Old 02-27-2008, 08:19 PM
Mother_Dee Mother_Dee is offline
 
Join Date: Jul 2007
Location: Wisconsin
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I apologize if I missed this, but our guild resides on a server with an apostrophe (Kael'thas) and I'm having issues:

The Armory pulls up those urls as:
character-sheet.xml?r=Kael%27thas&n=CHARNAME

not as:
character-sheet.xml?r=Kael'thas&n=CHARNAME

(ok well it does, sometimes, but the program doesn't give me information in mouseovers unless it's pulling up the top one, which is changed to the bottom or one with a released apostrophe on a refresh.)

So at this point I either get a very gimped version with only the username and guild and nothing more, and then on refresh of a thread I get absolutely nothing, a hang-up, or an armory error regarding the server not being found.

This would be nice to play around with, anyone have any further thoughts? I've played around a bit and haven't been able to find a work-around.
Reply With Quote
  #66  
Old 02-28-2008, 06:16 AM
hinch's Avatar
hinch hinch is offline
 
Join Date: May 2003
Location: UK
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm on Al'Akir also with the apostrophe and it worked fine setting the default to Al'Akir in the admin options you dont need to put the %27 in yourself just list the server name with the apostrophe and it should work it out its self when it does the armoury request.

yours not showing data could be armoury time out.
Reply With Quote
  #67  
Old 02-28-2008, 12:32 PM
Mother_Dee Mother_Dee is offline
 
Join Date: Jul 2007
Location: Wisconsin
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes, it seems the Armory crapped out for a good portion of the time before my raid. It worked fine after the raid ended, I apologize. What bizarre errors it was giving me, it definitely threw me for a loop there.

Thanks again, works great.
Reply With Quote
  #68  
Old 02-28-2008, 09:39 PM
sweede's Avatar
sweede sweede is offline
 
Join Date: Jan 2007
Posts: 391
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Mother_Dee View Post
I apologize if I missed this, but our guild resides on a server with an apostrophe (Kael'thas) and I'm having issues:

The Armory pulls up those urls as:
character-sheet.xml?r=Kael%27thas&n=CHARNAME

not as:
character-sheet.xml?r=Kael'thas&n=CHARNAME

(ok well it does, sometimes, but the program doesn't give me information in mouseovers unless it's pulling up the top one, which is changed to the bottom or one with a released apostrophe on a refresh.)

So at this point I either get a very gimped version with only the username and guild and nothing more, and then on refresh of a thread I get absolutely nothing, a hang-up, or an armory error regarding the server not being found.

This would be nice to play around with, anyone have any further thoughts? I've played around a bit and haven't been able to find a work-around.
Ya, it works, i had to fix that issue from the original author because my char resides on Vek'nilash

the reason why the ' doesnt work is because of the javascript code in the HTML to call the ajax.php file to get the info from armory and display it.

HTML Code:
onmouseover='ajax_showTooltip("http://www.dramaloot.com/forums/ajax.php?do=wowcharcode&amp;server=Vek'nilash&amp;char=Dragontaru",this); return false'
For some reason, i couldnt escape ' in the URL itself using either ' or \' so i just changed it to its code counterpart.
Reply With Quote
  #69  
Old 02-28-2008, 09:40 PM
sweede's Avatar
sweede sweede is offline
 
Join Date: Jan 2007
Posts: 391
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by hinch View Post
I also added this into my postbit but there's a much easier way of doing it than the one listed above.

Create a custom profile field for users called whatever you like in my case i called it wow main char. (field11)

user puts in the name of their wow char there.
Then i just edited the postbit_legacy and added in the following

HTML Code:
<if condition="$post[field11]">
<br />
<strong>WoW Char:</strong> <a style="cursor: pointer;" href="http://eu.wowarmory.com/character-sheet.xml?r=Al%27Akir&amp;n=$post[field11]" target="new" onmouseover="ajax_showTooltip(&quot;http://www.furious-angels.com/ajax.php?do=wowcharcode&server=Al'Akir&char=$post[field11]&quot;,this); return false" onmouseout="ajax_hideTooltip()">$post[field11]</a>
</if>
Don't forget to change your server and/or wowarmory.com locale !
Reply With Quote
  #70  
Old 02-28-2008, 10:36 PM
sweede's Avatar
sweede sweede is offline
 
Join Date: Jan 2007
Posts: 391
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by sweede View Post
Just as a notice, I plan on updating this in a few days.

Changes will include a more absract method of retreiving and storing character data from the armory. This will be a set of class methods that anyone can use to get , cache and display armory data.

Much better method of selecting what attributes to display. I'm also currently trying to figure out how to make character "roles" work, but am unsure if that would be a possibilty or even a wise idea, due to the amount of setup on the end users part it would require.

I would estimate a week or two before i have an update ready. If anyone has suggestions or any requests, let me know.
Just a little info on this progress.

I have the base classes that retreive and save the character information into the database. Everything is saved and will be in 2 tables (one for basic character information such as name, class, realm, etc and the other table is for all other stats).

Now i'm going to have to takle the hardest part, which is retreiving that information from the database.

I havent fully decided how to retrive that info. I know i'll have a subclass for each character class that will gather class specific details, but what to do about hybrid classes (such as a druid, which fits into dps caster, melee, tank, healer) , im not yet sure.

The planned usage of these classes will be something like,

$armory = new character(character, server, locale);
$armory->character_process();
$armory->get_stats("basic");
$armory->get_stats("melee","defense");

$armory->character_class; // would be the characters class
$armory->character_spec; // would be an array of points spent in the tree + the main trees name
$armory->health; // health, obviously
$armory->secondary; //rage or mana

Then for things like, crit you would have
$armory->crit_chance['melee']['perc']; // % crit chance, main hand melee
$armory->crit_chance['offhand']['value']; // crit rating (off hand).
$armory->crit_chance['spell']['perc']; // Returns %% of whatever your main specs crit chance is. i.e. if your link a mage and he's a frost mage but fire crit is 30% and frost crit is 28%, it will return 28%

Everything from the armory XML page will be available.

This will be a seperate include and will be available for use in any addon that you want to get armory character data from.

With the new class methods, i'll be able to allow a better degree of customization.

It may take a bit longer than planned, since i only really have one day a week to work on coding this.
Reply With Quote
  #71  
Old 02-29-2008, 07:25 AM
Infineon12 Infineon12 is offline
 
Join Date: Dec 2006
Posts: 3
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This thing is really great and i thank you for your work.

The problem i have is that like any other BBCode Manipulation (e.g. Itemstats) the things break on editing.
This makes it nearly unusable as i think.

I am currently thinking about a way to not edit the [char]Beherit[/char] in the Cache to the new Link Code, but to parse and replace thise links on the fly via javascript.

So that the code keeps [char]Beherit[/char] which also can be edited but on pageload the javascript replaces [char]*[/char] to the needed htmlCode.

Is there another way?
Reply With Quote
Reply


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

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

Forum Jump


All times are GMT. The time now is 02:27 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04718 seconds
  • Memory Usage 2,337KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (2)bbcode_html
  • (1)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete