Raised This Month: $12 Target: $400
 3% 

Solved Compiling error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
nG_getwreck
Senior Member
Join Date: Oct 2020
Location: Philippines from South K
Old 02-11-2021 , 00:20   Compiling error
Reply With Quote #1

Hello, I got problem when compiling this one.

Errors:
PHP Code:
//// ze_dfinth.sma
//
// dfinth.sma(118) : error 001: expected token: ")", but found ":"
// dfinth.sma(118) : error 029: invalid expression, assumed zero
// dfinth.sma(118) : warning 215: expression has no effect
// dfinth.sma(118) : error 001: expected token: ";", but found ")"
// dfinth.sma(118) : fatal error 107: too many error messages on one line
//
// Compilation aborted.
// 4 Errors.
// Could not locate output file compiled\dfinth.amx (compile failed).
//
// Compilation Time: 0.31 sec
// ---------------------------------------- 
Line 118:
PHP Code:
copy(text[++pos], sizeof text pos 1== ? (zp_core_is_zombie(id) ? " [Knockback Bomb]" " [Blind Bomb]" " [Kill Bomb]") : g_grenade_description[i]) 
__________________

Last edited by nG_getwreck; 02-11-2021 at 05:06.
nG_getwreck is offline
chickez
Junior Member
Join Date: Jun 2020
Location: Slovakia
Old 02-11-2021 , 03:50   Re: Compiling error
Reply With Quote #2

PHP Code:
condition YES NO //good
condition YES YES2 NO NO2 //bad

//------
//better for you to use
if ( condition )
    
YES
else
    
NO 
You have lot of to learn.
chickez is offline
nG_getwreck
Senior Member
Join Date: Oct 2020
Location: Philippines from South K
Old 02-11-2021 , 05:06   Re: Compiling error
Reply With Quote #3

Quote:
Originally Posted by chickez View Post
PHP Code:
condition YES NO //good
condition YES YES2 NO NO2 //bad

//------
//better for you to use
if ( condition )
    
YES
else
    
NO 
You have lot of to learn.
Thanks for this.
__________________
nG_getwreck is offline
Black Rose
Veteran Member
Join Date: Feb 2011
Location: Stockholm, Sweden
Old 02-12-2021 , 02:09   Re: Compiling error
Reply With Quote #4

Just to be clear.
PHP Code:
condition1 ? (yes1)condition2 yes2 no2 no1 //good
condition1 yes1 : (no1)condition2 yes2 no2 //good 
__________________

Last edited by Black Rose; 02-12-2021 at 02:09.
Black Rose is offline
Reply


Thread Tools
Display Modes

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 06:27.


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