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: [SOLVED] [QUESTION:WotlK] Some trouble with resources  (Read 856 times)

Medhi2703

  • Registred Member
  • MS Paint Freak
  • *****
  • Posts: 3
    • View Profile
[SOLVED] [QUESTION:WotlK] Some trouble with resources
« on: September 03, 2015, 01:03:29 am »
Hello everyone.
First, i'm sorry for my bad english(current&technics).
It's my first post and i have a problem. Haha.

I come here today because i have little problem.

I work actually on new Form for a new class.
It's simple, i work on Citizen class.
With this class, i create 3 form (like druid form)
I copy the line of the Catform on SpellShapeshiftForm.dbc to my new form (Light Fighter) with no morph.
And, i copy the line in spell.dbc for the new spell. I change the column 111 to new ID of my Shapeshift.
The form is ok but one thing don't work. The form don't change the mana to energy. :/

So i come here, if anyone have an idea for my problem.
Thanks for reading.

PS: I can upload my DBC file and some screen, if you want more information.
« Last Edit: September 05, 2015, 12:40:49 am by Admin »

XxXGenesisXxX

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 204
    • View Profile
Re: [QUESTION:WotlK] Some trouble with resources
« Reply #1 on: September 04, 2015, 04:49:51 pm »
You need to add a new case to the forms and make it change to whatever resource you would prefer. You would also have to edit it in the handler and probably as a shared define as well.

Code: [Select]
   switch (form)
    {
        case FORM_GHOUL:
        case FORM_CAT:
        {
            if (getPowerType() != POWER_ENERGY)
                setPowerType(POWER_ENERGY);
            break;
        }
        case FORM_BEAR:
        {
            if (getPowerType() != POWER_RAGE)
                setPowerType(POWER_RAGE);
            break;
        }
        default:                                            // 0, for example
        {
            ChrClassesEntry const* cEntry = sChrClassesStore.LookupEntry(getClass());
            if (cEntry && cEntry->PowerType < MAX_POWERS && uint32(getPowerType()) != cEntry->PowerType)
                setPowerType(Powers(cEntry->PowerType));
            break;
        }
    }

Player.cpp - Line 21210
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Medhi2703

  • Registred Member
  • MS Paint Freak
  • *****
  • Posts: 3
    • View Profile
Re: [QUESTION:WotlK] Some trouble with resources
« Reply #2 on: September 05, 2015, 12:40:09 am »
Thanks for you reply.
I fixed it with : Player.cpp, SpellAuraEffects.cpp, Unit.h and StatSystem.cpp
I would do an example tomorrow. :)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »