Raised This Month: $ Target: $400
 0% 

Dumb syntax error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
redivcram
Veteran Member
Join Date: Jul 2014
Location: Serbia
Old 11-04-2015 , 06:12   Dumb syntax error
Reply With Quote #1

#define TASK_COUNTUP 12345;

#define TADK_COUNTUP 12345

PHP Code:
public EvSpawn(id)
{
gTimerS[id] = 0;

if(
task_exists(TASK_COUNTUP id)) // line 50, TASK_COUNTUP defined as 12345;
{
remove_task(TASK_COUNTUP id);
}

if(
get_user_team(id) == 2)
{
Start(id);
}


Error:
Code:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2013 ITB CompuPhase, AMX Mod X Team

entity_solid.sma(50) : error 001: expected token: ",", but found ";"
entity_solid.sma(50) : error 036: empty statement
entity_solid.sma(50) : error 029: invalid expression, assumed zero
entity_solid.sma(50) : fatal error 107: too many error messages on one line

Compilation aborted.
4 Errors.

Last edited by redivcram; 11-05-2015 at 04:51.
redivcram is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-04-2015 , 09:39   Re: Dumb syntax error
Reply With Quote #2

The compiler doesn't make mistakes. Are you sure that that is line 50?
__________________

Last edited by fysiks; 11-04-2015 at 09:50.
fysiks is offline
redivcram
Veteran Member
Join Date: Jul 2014
Location: Serbia
Old 11-04-2015 , 14:17   Re: Dumb syntax error
Reply With Quote #3

I did something to confuse it.
Yes.. I checked before I even posted this

Edit: It appears that I, the genius, have put a semicolon when defined task hud

:}

Last edited by redivcram; 11-04-2015 at 15:04.
redivcram is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-04-2015 , 20:39   Re: Dumb syntax error
Reply With Quote #4

Quote:
Originally Posted by redivcram View Post
Solved

Dear beginners.. never use semicolons when defining.
  1. Don't remove your post. Simply add your solution to your post.
  2. Your claimed solution (the one that you posted) doesn't make sense. You should give an example.
__________________
fysiks is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:37.


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