Mercurial > wow > recipeprofit
comparison db_fix.lua @ 47:c6a4525f7ba7 v2.01a release
(none)
| author | "Aaron Bregger <killermonkey99@gmail.com>" |
|---|---|
| date | Tue, 04 Jan 2011 19:35:12 -0600 |
| parents | |
| children | bc43986f7fb0 |
comparison
equal
deleted
inserted
replaced
| 46:370eda9d0ea9 | 47:c6a4525f7ba7 |
|---|---|
| 1 --[[--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--)) | |
| 2 | |
| 3 RecipeProfit by -[@project-author@]- | |
| 4 | |
| 5 Rev: @project-revision@ | |
| 6 Updated: @file-date-iso@ | |
| 7 | |
| 8 --))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--)) | |
| 9 | |
| 10 URL: | |
| 11 http://www.wrathguides.com/ | |
| 12 | |
| 13 License: | |
| 14 This file is a part of "RecipeProfit for GatherMate." | |
| 15 | |
| 16 This program is free software; you can redistribute it and/or | |
| 17 modify it under the terms of the GNU General Public License | |
| 18 as published by the Free Software Foundation, either version 3 | |
| 19 of the License, or (at your option) any later version. | |
| 20 | |
| 21 This program is distributed in the hope that it will be useful, | |
| 22 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 23 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 24 GNU General Public License for more details. | |
| 25 | |
| 26 You should have received a copy of the GNU General Public License | |
| 27 along with Foobar. If not, see <http://www.gnu.org/licenses/>. | |
| 28 | |
| 29 Note: | |
| 30 This program's source code is specifically designed to work with | |
| 31 World of Warcraft's interpreted AddOn system. | |
| 32 | |
| 33 You have an implicit license to use this program with these facilities | |
| 34 since that is it's designated purpose as per: | |
| 35 http://www.fsf.org/licensing/licenses/gpl-faq.html#InterpreterIncompat | |
| 36 | |
| 37 --]]--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--))--)) | |
| 38 | |
| 39 | |
| 40 RECIPEPROFIT_location_cache = { | |
| 41 | |
| 42 } | |
| 43 | |
| 44 --[[ | |
| 45 Replaces the X and Y coordinates in the coordinate cached database. | |
| 46 ]--] | |
| 47 local function fix_coords(note, cdb) | |
| 48 for name, coord in pairs(cdb) do | |
| 49 if(note.vendor == name) then | |
| 50 note.x = coord.x * 100 | |
| 51 note.y = coord.y * 100 | |
| 52 end | |
| 53 end | |
| 54 end | |
| 55 | |
| 56 --[--[ | |
| 57 Overwrites RECIPEPROFIT_alliance and RECIPEPROFIT_horde dbs. | |
| 58 ]--] | |
| 59 do | |
| 60 for _, note in pairs(RECIPEPROFIT_alliance) do | |
| 61 fix_coords(note, RECIPEPROFIT_location_cache) | |
| 62 end | |
| 63 | |
| 64 for _, note in pairs(RECIPEPROFIT_horde) do | |
| 65 fix_coords(note, RECIPEPROFIT_location_cache) | |
| 66 end | |
| 67 end | |
| 68 ]] |
