ScriptDev2 Compilation

Results 1 to 12 of 12
  1. #1
    Apprentice e-reality is offline
    MemberRank
    Jul 2006 Join Date
    EstoniaLocation
    6Posts

    sad ScriptDev2 Compilation

    Hello everybody.

    Yesterday compiled latest mangos release with scripdev2 latest revision, and everything was ok.
    Today tried to compile last SD2 rev with latest mangos-0.12 branch, and I'm always getting errors.

    Code:
    1>..\include\sc_creature.cpp(545) : error C2065: 'UNIT_VIRTUAL_ITEM_SLOT_ID' : undeclared identifier
    1>..\include\sc_creature.cpp(548) : error C2065: 'UNIT_VIRTUAL_ITEM_SLOT_ID' : undeclared identifier
    1>..\include\sc_creature.cpp(551) : error C2065: 'UNIT_VIRTUAL_ITEM_SLOT_ID' : undeclared identifier
    1>..\include\sc_creature.cpp(463) : error C2661: 'MaNGOS::UnitLastSearcher<Check>::UnitLastSearcher' : no overloaded function takes 3 arguments
    1>        with
    1>        [
    1>            Check=MaNGOS::MostHPMissingInRange
    1>        ]
    1>..\scripts\world\item_scripts.cpp(52) : error C2065: 'SPELL_FAILED_NOT_ON_GROUND' : undeclared identifier
    I would be very glad if someone helped me.
    I'm using XP, latest Visual C++ 2008 Express.


  2. #2
    Proficient Member TrekPL is offline
    MemberRank
    Jun 2006 Join Date
    PolandLocation
    154Posts

    Re: ScriptDev2 Compilation

    One question: Have you run compatibility patch? Or did you check if there is (working)one for latest version?

  3. #3
    Apprentice e-reality is offline
    MemberRank
    Jul 2006 Join Date
    EstoniaLocation
    6Posts

    Re: ScriptDev2 Compilation

    Where can i get this patch?

  4. #4
    Proficient Member TrekPL is offline
    MemberRank
    Jun 2006 Join Date
    PolandLocation
    154Posts

    Re: ScriptDev2 Compilation

    It should be in: ScriptDev2\patches\custom\ScriptDev2_1318_to_MaNGOS_0.12.patch (or similar name with your version.)

    More info find at ScriptDev forum (hovewer it seems to be offline at the moment... )

  5. #5
    Apprentice e-reality is offline
    MemberRank
    Jul 2006 Join Date
    EstoniaLocation
    6Posts

    Re: ScriptDev2 Compilation

    Their forum is always offline.
    I have thit patch, but still can't use it :[ Can u tell me how to?

  6. #6
    Proficient Member TrekPL is offline
    MemberRank
    Jun 2006 Join Date
    PolandLocation
    154Posts

    Re: ScriptDev2 Compilation

    normal should like something like this: (you should be in mangos root)
    Code:
    git apply src/bindings/ScriptDev2/patches/<Your_ScriptDev_patch>
    However sometimes you get error due code incompatibility - you can patch code manually then. I will show you how but you should be warned - I have no idea if this will work with newest branch.

    So, instruction:

    In *.patch file you will find something like this:
    Code:
    --- include/sc_creature.cpp	(revision 1318)
    +++ include/sc_creature.cpp	(working copy)
    @@ -460,7 +460,7 @@
         Unit* pUnit = NULL;
     
         MaNGOS::MostHPMissingInRange u_check(m_creature, fRange, uiMinHPDiff);
    -    MaNGOS::UnitLastSearcher<MaNGOS::MostHPMissingInRange> searcher(m_creature, pUnit, u_check);
    +    MaNGOS::UnitLastSearcher<MaNGOS::MostHPMissingInRange> searcher(pUnit, u_check);
    Translating: in file "include/sc_creature.cpp" from line "460" (or near it) look for line "MaNGOS::UnitLastSearcher<MaNGOS::MostHPMissingInRange> searcher(m_creature, pUnit, u_check);" and delete it (with "-" sign) then put there "MaNGOS::UnitLastSearcher<MaNGOS::MostHPMissingInRange> searcher(pUnit, u_check);"

    As you can see you have to delete all lines with "-" sign and then add lines (most cases in place of those deleted ones) new.

    This is long and boring but it "might" work ( I don't give 100% proof for that because as I have said earlier I don;t know if it is compatible with newest branch).

    Happy patching
    Last edited by TrekPL; 11-10-09 at 07:54 PM.

  7. #7
    Apprentice e-reality is offline
    MemberRank
    Jul 2006 Join Date
    EstoniaLocation
    6Posts

    Re: ScriptDev2 Compilation

    Thank you very much. I will try this in the evening.

    Getting other errors now. :[
    Last edited by e-reality; 12-10-09 at 05:46 PM.

  8. #8
    Omega FragFrog is offline
    MemberRank
    Aug 2004 Join Date
    The NetherlandsLocation
    5,630Posts

    Re: ScriptDev2 Compilation

    Quote Originally Posted by TrekPL View Post
    normal should like something like this: (you should be in mangos root)
    Code:
    git apply src/bindings/ScriptDev2/patches/<Your_ScriptDev_patch>
    This is incorrect. ScriptDev2 compatability patches are SVN patches, not GiT, so I very much doubt applying them using GiT will work. There is a GiT patch for integrating SD2, but the compatability patch is SVN.

    Unfortunately, there is no working patch (yet) for SD2-1436 and higher to get to the
    TBC branch. Latest SD2 I tried that seemed to work was 1397 (although you can manually resolve the 3 or so conflicts that arise with 1436, but you'll have to know what you're doing for that).

    Easiest solution is to do a checkout of SD2, get TortoiseSVN, RMB the 'scriptdev2' folder -> 'Tortoise SVN' -> 'Update to revision...' -> enter something like 1397.

    Then RMB the 'scriptdev2' folder again, 'TortoiseSVN' -> 'Apply patch...' -> select the 'scriptdev2/patches/custom/ScriptDev2_1318_to_MaNGOS_0.12.patch' file -> 'RMB the popup -> 'Patch All'
    Last edited by FragFrog; 12-10-09 at 04:32 PM.

  9. #9
    Proficient Member TrekPL is offline
    MemberRank
    Jun 2006 Join Date
    PolandLocation
    154Posts

    Re: ScriptDev2 Compilation

    Quote Originally Posted by FragFrog View Post
    This is incorrect. ScriptDev2 compatability patches are SVN patches, not GiT, so I very much doubt applying them using GiT will work. There is a GiT patch for integrating SD2, but the compatability patch is SVN.

    Unfortunately, there is no working patch (yet) for SD2-1436 and higher to get to the
    TBC branch. Latest SD2 I tried that seemed to work was 1397 (although you can manually resolve the 3 or so conflicts that arise with 1436, but you'll have to know what you're doing for that).

    Easiest solution is to do a checkout of SD2, get TortoiseSVN, RMB the 'scriptdev2' folder -> 'Tortoise SVN' -> 'Update to revision...' -> enter something like 1397.

    Then RMB the 'scriptdev2' folder again, 'TortoiseSVN' -> 'Apply patch...' -> select the 'scriptdev2/patches/custom/ScriptDev2_1318_to_MaNGOS_0.12.patch' file -> 'RMB the popup -> 'Patch All'
    @FragFrog: nvm. Mangos is available from GiT repo... from where you DL it as SVN?

    @e-reality: ScriptDev and look for backport / 0.12
    Last edited by TrekPL; 12-10-09 at 05:58 PM.

  10. #10
    Apprentice e-reality is offline
    MemberRank
    Jul 2006 Join Date
    EstoniaLocation
    6Posts

    Re: ScriptDev2 Compilation

    Thank you for help guys. You helped me much :)

  11. #11
    Omega FragFrog is offline
    MemberRank
    Aug 2004 Join Date
    The NetherlandsLocation
    5,630Posts

    Re: ScriptDev2 Compilation

    Quote Originally Posted by TrekPL View Post
    @FragFrog: nvm. Mangos is available from GiT repo... from where you DL it as SVN?
    Which part of "ScriptDev2" was unclear exactly? TS wants to compile SD2, not Mangos. For that, he needs the ScriptDev2 patch, which is SVN since ScriptDev2 uses SVN. In fact, I didn't even use the word Mangos anywhere in my post (except as part of the patch filename quote).
    Last edited by FragFrog; 13-10-09 at 12:56 AM.

  12. #12
    Proficient Member TrekPL is offline
    MemberRank
    Jun 2006 Join Date
    PolandLocation
    154Posts

    Re: ScriptDev2 Compilation

    Quote Originally Posted by FragFrog View Post
    Which part of "ScriptDev2" was unclear exactly? TS wants to compile SD2, not Mangos. For that, he needs the ScriptDev2 patch, which is SVN since ScriptDev2 uses SVN. In fact, I didn't even use the word Mangos anywhere in my post (except as part of the patch filename quote).
    My fault... I was "little tired" yesterday ;P

    <communication_end>
    Last edited by TrekPL; 13-10-09 at 10:59 AM.



Advertisement