Please lads, could any of you tell me ,very noob friendly, how to import new cpp scripts to oregon core? Thanks in advance

First of all, importing from other systems is never noob friendly and needs knowledge of both systems and how to rewrite things.

to tell you more i need more infos:
importing from where? Trinity? Mangos? Older OC Versions?

I am not that noob, I have certain knowledge of it, just never did it before. I compiled oregon core 2.4.3 on debian, and now I see there are some nice scripts which I would like to add to my server. That is what I am asking smile

Go to src\scripts\Custom paste your c++ script
go to src\game\Scriptloader.cpp , open and
void AddSC_yourcode();
and down

Save. And recompile

I dont quite understand what that means. I need step by step instruction that I could understand xD

6 (edited by Selphius 2016-04-06 17:56:37)

It says to copy and paste your custom cpp to this folder in your project (depends what core you use). In OregonCore case it would be path "src\scripts\Custom" you go into this folder and paste custom script there.

Second step is to add those scripts to core. Again in OregonCore case it would be opening your project, then navigating to this path "src\game\Scriptloader.cpp" and there declaring your new script by

void AddSC_yourcode();

and down


For example, my custom script is:

CreatureAI* GetAI_npc_searing_elemental(Creature* pCreature)
    return new npc_searing_elementalAI(pCreature);

So in ScriptLoader.cpp I declare it like that:

void AddSC_npc_searing_elemental();

and down


Then compile it and build.

Thank you!