User:Nighty/sandbox6: Difference between revisions

From Path of Exile Wiki
Jump to navigation Jump to search
(fixed many typos (carefully))
 
(test)
Line 12: Line 12:
     missing_monster: 'No monster found with <!--{$metadata_id}-->',
     missing_monster: 'No monster found with <!--{$metadata_id}-->',
     calculating: 'Calculating properties',
     calculating: 'Calculating properties',
     query_error: 'A database query error has occurred.',
     query_error: 'A database query error has occured.',
     invalid_rarity: 'Rarity given is invalid. Only Normal, Magic, Rare and Unique are acceptable values.',
     invalid_rarity: 'Rarity given is invalid. Only Normal, Magic, Rare and Unique are acceptable values.',
     invalid_difficulty: 'Difficulty given is invalid. Only part1, part2 and endgame are acceptable values.',
     invalid_difficulty: 'Difficulty given is invalid. Only part1, part2 and endgame are acceptable values.',
Line 73: Line 73:
         </tr>
         </tr>
         <tr>
         <tr>
             <th>Difficulty</th>
             <th>Difficuty</th>
             <td><select name="difficulty">
             <td><select name="difficulty">
                   <option value="part1" selected>Part 1</option>
                   <option value="part1" selected>Part 1</option>
Line 339: Line 339:
             func_stat(this);
             func_stat(this);
         } else {
         } else {
             throw 'Stat arithmetic requires a stat object or number, got type "' + t + '"';
             throw 'Stat arithmetric requires a stat object or number, got type "' + t + '"';
         }
         }
     }
     }
Line 580: Line 580:
         this.html.find('em.monster_name').html(this.data['monsters.name']);
         this.html.find('em.monster_name').html(this.data['monsters.name']);
          
          
         // Can be directly inserted into the relevant fields
         // Can be directly inserted into the releveant fields
         for (const [i, key] of Object.entries([
         for (const [i, key] of Object.entries([
             'size',
             'size',
Line 713: Line 713:
         }
         }
          
          
         // Must be toggled off before changing the value to make sure the stats are removed correctly
         // Must be toggled off before changing the value to make sure the stats are removed correclty
         if (is_map_monster) {
         if (is_map_monster) {
             this.ctl.find('input[name="is_map_boss"]').prop('disabled', false);
             this.ctl.find('input[name="is_map_boss"]').prop('disabled', false);
Line 877: Line 877:
         }
         }
          
          
         // Overriding is a special case that ignores all further calculations
         // Overriding is a special case that ingores all further calcuations
         var stats = this.stats;
         var stats = this.stats;
         if (typeof calc.override !== 'undefined') {
         if (typeof calc.override !== 'undefined') {
Line 992: Line 992:
Monster.base_data_by_id = {};
Monster.base_data_by_id = {};


// Map these stats back for calculation purposes
// Map these stats back for calcuation purposes
Monster.stat_map = {
Monster.stat_map = {
     ['map_life_multiplier']: 'map_hidden_monster_life_+%_final',
     ['map_life_multiplier']: 'map_hidden_monster_life_+%_final',
Line 1,182: Line 1,182:
function _run_final_init() {
function _run_final_init() {
     init_level = init_level + 1;
     init_level = init_level + 1;
     // Prevents from being run until all the cargo data is asynchronously loaded
     // Prevents from being run until all the cargo data is asyncronously loaded
     if (init_level >= init_max) {
     if (init_level >= init_max) {
       monster_finalize_init();
       monster_finalize_init();
Line 1,247: Line 1,247:
             'monsters.metadata_id',
             'monsters.metadata_id',
             'monsters.name',
             'monsters.name',
             // Apparently strips the table if I don't do this
             // Apprently strips the table if I don't do this
             'monsters.tags__full=monsters.tags',
             'monsters.tags__full=monsters.tags',
             'monsters.skill_ids',
             'monsters.skill_ids',
Line 1,258: Line 1,258:
             //
             //
              
              
             // Apparently strips the table if I don't do this
             // Apprently strips the table if I don't do this
             'monster_types.tags__full=monster_types.tags',
             'monster_types.tags__full=monster_types.tags',
             // This is kinda unconfirmed, want to leave it out for the moment
             // This is kinda unconfirmed, want to leave it out for the moment

Revision as of 09:45, 25 January 2023

Documentation[create] [purge]