This is a read only copy without any forum functionality of the old Modcraft forum.
If there is anything that you would like to have removed, message me on Discord via Kaev#5208.
Big thanks to Alastor for making this copy!

Menu

Author Topic: Fly mount on Azeroth ( or Own map )  (Read 3526 times)

athert

  • Registred Member
  • BLP Convertor
  • *****
  • Posts: 9
    • View Profile
Fly mount on Azeroth ( or Own map )
« on: June 26, 2012, 10:48:10 am »
Hi all.. i have one problem with Fly mount on my own map. I look at spell.cpp and etc., but i cant find something about " allow " flying ( something " if(map != 530 ){ // no you really cant fly on this map } ).. i look on internet but i find something only for ArcEmu or Tc2 but only for old version.. my server work on TC2.
Sry for bad english and thanks for read.. :)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Zim4ik

  • Contributors
  • Creator of Worlds
  • *****
  • Posts: 407
    • View Profile
Re: Fly mount on Azeroth ( or Own map )
« Reply #1 on: June 26, 2012, 11:59:25 am »
change flags at spell.dbc
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ascathos

  • Moderators
  • Creator of Worlds
  • *****
  • Posts: 1129
    • View Profile
Re: Fly mount on Azeroth ( or Own map )
« Reply #2 on: June 26, 2012, 03:21:40 pm »
Actually, I am not sure what flag you'd want to change in the dbc. Can't find the "necessary" one actually.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Vel

  • Contributors
  • Creator of Worlds
  • *****
  • Posts: 340
    • View Profile
Re: Fly mount on Azeroth ( or Own map )
« Reply #3 on: June 26, 2012, 07:54:30 pm »
see zone flags in areatable.dbc and update this dbc on the server (but but I'm not quite sure...)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
is no more

glararan

  • Registred Member
  • Wiki Incarnate
  • *****
  • Posts: 162
    • View Profile
    • http://glararan.eu
Re: Fly mount on Azeroth ( or Own map )
« Reply #4 on: June 26, 2012, 08:00:56 pm »
If you find on old version why you dont update it to current?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ascathos

  • Moderators
  • Creator of Worlds
  • *****
  • Posts: 1129
    • View Profile
Re: Fly mount on Azeroth ( or Own map )
« Reply #5 on: June 26, 2012, 09:58:22 pm »
After doing some tests, I have to agree and thank Vel. This one is doing the job and you have to set additional 0x400 (or 0x4400) bytes to the 5th point, flag. Note that this has to be done individual.

Moving from an area providing flight into one without flight doesn't disable or deactivate already activated ones. You can not re-apply flight in areas where it is not enabled. Enabling flight in Azeroth or custom maps might always result in a buggy character, as they gain access to areas beyond a players reach. Choose wisely how and what you do.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

sevi

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 56
    • View Profile
Re: Fly mount on Azeroth ( or Own map )
« Reply #6 on: July 18, 2012, 12:43:53 am »
the area must have the right areaflag, see above me.

but this allone is not enough under trinitycore.
the core self is checking can the player fly in this map.
so you will fly in a custom map, then must you change some thinks in the core files from trinitycore.

spells_generic.cpp

here you search following line in this cpp:

Code: [Select]
if (map == 530 || (map == 571 && target->HasSpell(SPELL_COLD_WEATHER_FLYING)))
this change you to:

Code: [Select]
if (map == 530 || (map == 571 && target->HasSpell(SPELL_COLD_WEATHER_FLYING)) || map = yourmapid)
but this is not all.
in the spellinfo.cpp ist following checking:

Code: [Select]
!mapEntry->IsContinent()so your map is not a continent for the core, switch in this cpp:

DBCStructure.h

here search you following code line:

Code: [Select]
bool IsContinent() const
     {
-        return MapID == 0 || MapID == 1 || MapID == 530 || MapID == 571;
+        return MapID == 0 || MapID == 1 || MapID == 530 || MapID == 571;
     }

this change you in this:

Code: [Select]

bool IsContinent() const
     {
-        return MapID == 0 || MapID == 1 || MapID == 530 || MapID == 571;
+        return MapID == 0 || MapID == 1 || MapID == 530 || MapID == 571 || MapID == yourmapid;
     }

Now you compiling the core and then you can fly in custom map.
before extract the current map files whit the new map/areas.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »