AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugin/Gameplay Ideas and Requests (https://forums.alliedmods.net/forumdisplay.php?f=60)
-   -   help i cant compile files (https://forums.alliedmods.net/showthread.php?t=312566)

benmassey 12-08-2018 11:25

help i cant compile files
 
i have a problem i cant compile sp files
i try to compile with compiler.exe
but everytime when i try to compile its send me a lot of errors
even with a simple script someone know why?

i tried to compile
Code:

#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

public void OnPluginStart()
{
    RegConsoleCmd("sm_discord", CMD_sa, "Welcome message");
   
    HookEvent("round_start", Hook_roundstart);
}

public Action CMD_discord(int client, int args)
{
    PrintToChat(client, " \x05 Welcome to my Server \x01 GL&HF");
}

public Action Hook_roundstart(Event event, const char[] name, bool dontBroadcast)
{
    CreateTimer(120.0, welcome_timer, TIMER_REPEAT);
}

public Action welcome_timer(Handle timer)
{
    PrintToChatAll(" \x05 Welcome to my Server \x01 have fun!");
}

and that's the errors:

Code:

//// adver.sp
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(4) : warning 207: unknown #pragma
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(4) : error 038: extra characters on line
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(6) : error 001: expected token: ";", but found "-identifier-"
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(13) : error 021: symbol already defined: "Action"
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(13) : error 010: invalid function or declaration
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(18) : error 021: symbol already defined: "Action"
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(18) : error 017: undefined symbol "event"
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(18) : error 029: invalid expression, assumed zero
// C:\server's\csgo\csgo\addons\sourcemod\scripting\adver.sp(18) : fatal error 127: too many error messages on one line
//
// Compilation aborted.
// 8 Errors.
//
// Compilation Time: 0.14 sec



All times are GMT -4. The time now is 11:47.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.