• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

[SOLVED] Such a problem

Status
Not open for further replies.

igotDiamonds

New member
Hello guys, first of all im new to C++ and core development, also not good in English\n

The problem is:
I compiled the core without errors, started, tested, then i wanted to try making some Custom scripts with GOSSIP_MENU bla bla
and i met the problem #include "ScriptPCH.h" saying "Can't open source file..." but it is in the directory, also i manually inserted path to it like #include "/src/blabla/ScriptPCH.h" and then ADD_GOSSIP_MENU don't work anyway

Sorry for my Eng
 

Sylica

Exalted Member
Hello guys, first of all im new to C++ and core development, also not good in English\n

The problem is:
I compiled the core without errors, started, tested, then i wanted to try making some Custom scripts with GOSSIP_MENU bla bla
and i met the problem #include "ScriptPCH.h" saying "Can't open source file..." but it is in the directory, also i manually inserted path to it like #include "/src/blabla/ScriptPCH.h" and then ADD_GOSSIP_MENU don't work anyway

Sorry for my Eng

Try using ScriptMgr.h instead of ScriptPCH.h in the file. This has change in TrinityCore if that is the core you are using.

I hope this helps.
 

Rochet2

Moderator / Eluna Dev
instead of scriptpch you should include what you use. you cannot inlcude scriptpch anymore as said above.
for example Player.h and Creature.h if you use Player and Creature classes and so on.
ScriptMgr.h is required when you use script classes like PlayerScript etc. so pretty much always.

For the gossip code, in TC 3.3.5 they changed the functions. See bottom of ScriptedGossip.h for the new functions you should use.
You can also take a look at existing scripts in src/server/scripts/world/ and see how they code gossip stuff.
 
Status
Not open for further replies.
Top