Importing custom script error

So I’ve been trying to create a world chat scrip. I followed a youtube guide. But when im trying to add it to my server it wont work…

Here’s the code http://piratepad.net/LmPFZMVDfi

I've added 
"set(scripts_STAT_SRCS
  ${scripts_STAT_SRCS}
  Custom/chat.cpp
" to CMakeList in "\src\server\scripts\Custom"

And I’ve added

"
#ifdef SCRIPTS
/* This is where custom scripts’ loading functions should be declared. */
void AddSC_chat();

#endif

void AddCustomScripts()

{
#ifdef SCRIPTS
/* This is where custom scripts should be added. */

    AddSC_chat();

#endif
}
" In the ScriptLoader.cpp

Then I right clicked “Source Files” in VS and → add → “exisiting item”

Then I clicked “Rebuild”

[ATTACH]1637._xfImport[/ATTACH]

Change #include “ScriptPCH.h” to [COLOR=rgb(51,51,51)]#[COLOR=rgb(167,29,93)]include[COLOR=rgb(51,51,51)] [COLOR=rgb(24,54,145)]“ScriptMgr.h[COLOR=rgb(24,54,145)]”