Files
aowow/setup/tools/sqlgen/itemenchantment.func.php
Sarjuuk 7f08708555 added enchantments to DB
* added markdown [enchantment=123] and [emote=456]
 * updated item_stats to accomodate enchantments
 * updated tables for community content to handle emotes and enchantments

Spells:
 * getStatGain() now reads aura 123 as Spell Penetration
 * fixed error in tooltips when displaying effect ranges (e.g. 10 - 10 damage)
 * display the miscValue of aura 50, 102, 131 and 180 human readable

Emote:
 * no longer displays empty quickInfo on detail page
 * detail page no longer pretends to be a pet

Setup:
 * sync no longer regenerates all tables/files, when the supplied world-table affects nothing
 * fixed dependancy of ?_source from ?_achievment (damn plural-s)

Misc:
 * FireFox doesn't understand <node>.innerText, use <node>.textContent instead

please refresh the affected tables and files
   php aowow --sql=itemenchantment,item_stats
   php aowow --build=enchants,gems
2015-08-03 20:05:39 +02:00

38 lines
1.2 KiB
PHP

<?php
if (!defined('AOWOW_REVISION'))
die('illegal access');
if (!CLI)
die('not in cli mode');
$customData = array(
);
$reqDBC = ['spellitemenchantment'];
function itemenchantment()
{
$baseQuery = '
REPLACE INTO
?_itemenchantment
SELECT
Id, charges, 0, 0, 0, type1, type2, type3, amount1, amount2, amount3, object1, object2, object3, name_loc0, name_loc2, name_loc3, name_loc6, name_loc8, conditionId, skillLine, skillLevel, requiredLevel
FROM
dbc_spellitemenchantment';
DB::Aowow()->query($baseQuery);
$cuProcs = DB::World()->select('SELECT entry AS ARRAY_KEY, customChance AS procChance, PPMChance AS ppmRate FROM spell_enchant_proc_data');
foreach ($cuProcs as $id => $vals)
DB::Aowow()->query('UPDATE ?_itemenchantment SET ?a WHERE id = ?d', $vals, $id);
// hide strange stuff
DB::Aowow()->query('UPDATE ?_itemenchantment SET cuFlags = ?d WHERE type1 = 0 AND type2 = 0 AND type3 = 0', CUSTOM_EXCLUDE_FOR_LISTVIEW);
DB::Aowow()->query('UPDATE ?_itemenchantment SET cuFlags = ?d WHERE name_loc0 LIKE "%test%"', CUSTOM_EXCLUDE_FOR_LISTVIEW);
return true;
}
?>