Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

ScriptDev2 Compilation

Newbie Spellweaver
Joined
Jul 14, 2006
Messages
6
Reaction score
0
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.
 
Junior Spellweaver
Joined
Jun 21, 2006
Messages
123
Reaction score
2
One question: Have you run compatibility patch? Or did you check if there is (working)one for latest version?
 
Junior Spellweaver
Joined
Jun 21, 2006
Messages
123
Reaction score
2
It should be in: ScriptDev2\patches\custom\ScriptDev2_1318_to_MaNGOS_0.12.patch (or similar name with your version.)

More info find at forum (hovewer it seems to be offline at the moment... :(: )
 
Newbie Spellweaver
Joined
Jul 14, 2006
Messages
6
Reaction score
0
Their forum is always offline.
I have thit patch, but still can't use it :[ Can u tell me how to?
 
Junior Spellweaver
Joined
Jun 21, 2006
Messages
123
Reaction score
2
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 :eek:tt1:
 
Last edited:
Newbie Spellweaver
Joined
Jul 14, 2006
Messages
6
Reaction score
0
Thank you very much. I will try this in the evening.

Getting other errors now. :[
 
Last edited:
Custom Title Activated
Loyal Member
Joined
Aug 8, 2004
Messages
3,892
Reaction score
20
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:
Junior Spellweaver
Joined
Jun 21, 2006
Messages
123
Reaction score
2
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: and look for backport / 0.12
 
Last edited:
Custom Title Activated
Loyal Member
Joined
Aug 8, 2004
Messages
3,892
Reaction score
20
@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:
Junior Spellweaver
Joined
Jun 21, 2006
Messages
123
Reaction score
2
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:
Back
Top