Jump to content

DiSlord

Members
  • Posts

    59
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Everything posted by DiSlord

  1. Nex try pack also height data (lost some accuracy but get better file size) now all maps req 290 Mb ram. Now height stored as uint8/uint16/float - depend from max grid heigh diff (in 40% use uint8 ). + less maps size - lost some accuracy in some places (but not more than 0.01) [added] fixed some typos http://depositfiles.com/files/qvwmif0c3
  2. Its not this patch problem i think (test it on clean mangos and get some results) Need fill game_graveyard_zone table
  3. Update patch Fixed: - Memory leak - Not closed map file in some cases - Speedup (now as fast as possible) get liquid data - Extract map by use WDT files (contain grid lists) - Store dark water data from MH2O to .map file - Fixed wrong asrea store in some cases http://depositfiles.com/files/3ebnha1gf PS need reextract maps
  4. Example in greed water: ~ water # earth 1 ) ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ Add have constant level 0.0f - example ochean. Store only uint8 liquidType, and float liquidLevel = 0.0f - only 5 bytes (except 64 kb before). 2) ~~~##### ~~~~#### ~~~~~### ~~~~~~## ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ And constant level - store only matrix uint8 16x16 liquid type and float level - 260 bytes 3) #####~~# ####~~## ###~~### #~~~~~~# #~~~~~~# ######## ######## And not constant level (waterfall for example) Select only water area (xoffs, y offs, width, height) ####~~ ###~~# ##~~## ~~~~~~ ~~~~~~ Store uint8 16x16 liquid type and width*height liquid height data < 64 kb 4) ######## ######## ######## ######## ######## ######## ######## ######## No liquids - nothing store - 0 bytes
  5. Continue work under .map files: How possible limit .map size? Liquids level stored as 128x128 float array in every griid, but in most cases liquids have constant level and need just know it, or if no liquids in greed - not need store it (its also for area data and height data). I also add some improvements in .map file format. Now .map size 619 Mb (1 Gb before) (on load in memory maps also need only 619 Mb). And code should be faster as before. I also rewrite .adt extractor, and don`t have any error on extract maps (also i hope fixed water damage as lava). Download http://depositfiles.com/files/3ebnha1gf [added] Next try pack also height data (lost some accuracy but get better file size) now all maps req 290 Mb ram. Now height stored as uint8/uint16/float - depend from max grid heigh diff (in 40% use uint8 ). + less maps size - lost some accuracy in some places (but not more than 0.01) http://depositfiles.com/ru/files/8gxr54z34 [added] Not store height data in deep ochean (dark water), limit it to -230. Its allow save some memory for maps. Also use better float->int conversion and get better accuracy (max mistake = 0.002 by my tests) Now all maps size = 217 Mb DOWNLOAD
  6. This added in code (use MAP_3.00 in header and check on load)
  7. try init variables float a,b,c; like float a=0,b=0,c=0; and test again on 7291 revision..
  8. No, but possible i try fix it, if continue work under maps
  9. Map height - is used in most random movement generators: in some cases you can drop under textures in Fear (if points set go under it) try fear in hills before and after. Also used in summons (for detect ground) - try summon totem in hills before and after.
  10. In client files (.adt) height map stored as: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 But on .map generation converted in this format: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 On conversion added additional data and also lost accuracy (on data interpolation) This patch use .adt format for store height map in .map files its give: 1 - less memory usage (before for maps used 1.66 Gb, after 1Gb) 2 - Must be more correct heigh calculation (on test i get accuracy 3-4 sign after comma) 3 - Height calculation not more difficult as before (bilinear interpolation), used interpolation on triangles. here is - fixed ad.exe for extract .map files and patch.. [added] test maps (use .gps command and compare my Z coordinate, and Map Height) Old maps - get +-1 mistake on some points (in hills) My mps +-0,001 mistake in all points Source: // Height stored as: h5 - its v8 grid, h1-h4 - its v9 grid // +--------------> X // | h1-------h2 Coordinates is: // | | \\ 1 / | h1 0,0 // | | \\ / | h2 0,1 // | | 2 h5 3 | h3 1,0 // | | / \\ | h4 1,1 // | | / 4 \\ | h5 1/2,1/2 // | h3-------h4 // V Y // For find height need // 1 - detect triangle // 2 - solve linear equation from triangle points // Calculate coefficients for solve h = a*x + b*y + c float a,b,c; // Select triangle: if (lx+ly < 1) { if (lx > ly) { // 1 triangle (h1, h2, h5 points) float h1 = gmap->v9[lx_int][ly_int]; float h2 = gmap->v9[lx_int+1][ly_int]; float h5 = 2 * gmap->v8[lx_int][ly_int]; a = h2-h1; b = h5-h1-h2; c = h1; } else { // 2 triangle (h1, h3, h5 points) float h1 = gmap->v9[lx_int][ly_int]; float h3 = gmap->v9[lx_int][ly_int+1]; float h5 = 2 * gmap->v8[lx_int][ly_int]; a = h5 - h1 - h3; b = h3 - h1; c = h1; } } else { if (lx > ly) { // 3 triangle (h2, h4, h5 points) float h2 = gmap->v9[lx_int+1][ly_int]; float h4 = gmap->v9[lx_int+1][ly_int+1]; float h5 = 2 * gmap->v8[lx_int][ly_int]; a = h2 + h4 - h5; b = h4 - h2; c = h5 - h4; } else { // 4 triangle (h3, h4, h5 points) float h3 = gmap->v9[lx_int][ly_int+1]; float h4 = gmap->v9[lx_int+1][ly_int+1]; float h5 = 2 * gmap->v8[lx_int][ly_int]; a = h4 - h3; b = h3 + h4 - h5; c = h5 - h4; } } // Calculate height float _mapheight = a * lx + b * ly + c; As you can see this method not more hard for equation (and in some cases ease than bilinear interpolation ), and give wondefull results on my tests
  11. Added in 7263 (also use this mod for enchants)
  12. Need remove 60200 from spell_proc_event table (spell changed in 308)
  13. Some crashes related in ObjectAccessor::GetDynamicObject ObjectAccessor::GetGameObject Unit::CalcAbsorbResist must be fixed in 7197
  14. Better use triggeredByAura->GetModifier().m_amountAnd use as before one trigger in dumy one as triggerSpell
  15. Better Try fix Family flag inline bool IsSealSpell(SpellEntry const *spellInfo) { //Collection of all the seal family flags. No other paladin spell has any of those. return spellInfo->SpellFamilyName == SPELLFAMILY_PALADIN && ( spellInfo->SpellFamilyFlags & [b]0x26000C000A000000LL[/b] ); } and [color=Black]if (spellInfo->SpellFamilyFlags & [b]0x0000000011010002L[/b][/color][color=Black][b]L[/b]) return SPELL_BLESSING;[/color]
  16. DiSlord

    GetFloatValue

    if you need do convert in php: $float = unpack("f", pack("L",$char_data[$i]));
  17. Quest http://www.wowhead.com/?quest=9805 On cast http://www.wowhead.com/?spell=31927 you summon fire elemental and activate flame objects (make them visible) you can see it in gm mode (but can`t if you player) for create burning tower. Need activate up to 5 (or more) fires. Quest http://www.wowhead.com/?quest=1103 8899 Sapta Sight spell - req spell focus, but object for activate (need show glowing aura) can be to far away. PS i can wrong about spell id (its one from shaman sapta quest)
  18. As i remember TARGET_SCRIPT_GAMEOBJECT used for activate GO spell effect (in most cases) For this TARGET_SCRIPT_GAMEOBJECT should support select 1 - N GO in radius (in some spell effect need activate multiple GO for example show up to 5 fire GO on summon fire elemental in one quest, or only one GO for put rocket in Cluster Launcher for example) and need do it around spell focus target if its possible (in one quest need show glow aura around elementals, but you can cast to far from this GO, but in spell focus radius). I hope you understand me.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use