Raised This Month: $ Target: $400
 0% 

Need bit help :)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
jonnzus
Epic Member
Join Date: Oct 2010
Location: Finland
Old 01-31-2013 , 17:14   Need bit help :)
Reply With Quote #1

Can someone explain what I have done wrong, and how I could fix it?
And what about ; ?
When it's needed in pawn?

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <csx>


new String:command[] = "gal_startvote"//Command witch is executed when team has winscores.
new String:winningMsg[] = "";
new 
CTKILLS 0;
new 
TKILLS 0;
new 
winscores 10;

/*
enum winningteam {
    CT = 0,
    T = 1,
    TIE = 2
}
*/

new winningteam 0;


public 
plugin_init() {
    
register_plugin("DeathMach Win""1.0.0""Jonuz")
    
register_clcmd("/status""scoreStatus")
    
register_clcmd("/winning""informer")
}

    public 
getKills(attacker) {
        if (
cs_get_user_team(attacker) == CS_TEAM_CT) {
        
CTKILLS++
    }
        if (
cs_get_user_team(attacker) == CS_TEAM_T) {
        
TKILLS++
    }}

    public 
scoreStatus(id) {
        
client_print (id,print_chat"Ct have: %CTKILLS kills.")
        
client_print (id,print_chat"Terrorist have: %TKILLS kills.")
    }

    public 
Win() {
        if (
CTKILLS == winscores) {
            
server_print ("Counter terrorist team has won game.")
            
server_cmd ("gal_startvote")
    }
        
        if (
TKILLS == winscores) {
            
server_print ("Terrorist steam has won game.")
            
server_cmd (command)
    }}

    public 
informer () {

        if (
CTKILLS TKILLS) {
            
winningteam 0
        
} else if (CTKILLS TKILLS) {
            
winningteam 1
        
} else if (CTKILLS == TKILLS) {
            
winningteam 2
        
}

        if (
winningteam 0) {
            
winningMsg "Ct needs  winscores - CTKILLS kill to win game.";
        } else if (
winningteam 1) {
            
winningMsg "Terrorist team need winninscores - TKILLS kill to win game.";
        }
            
        
server_print (winningMsg)
        
winningMsg "";
        } 
Compile error:
Code:
csdmwin.sma(7) : warning 213: tag mismatch
csdmwin.sma(8) : warning 213: tag mismatch
csdmwin.sma(51) : warning 213: tag mismatch
csdmwin.sma(64) : warning 211: possibly unintended assignment
csdmwin.sma(65) : error 047: array sizes do not match, or destination array is too small
csdmwin.sma(66) : warning 211: possibly unintended assignment
csdmwin.sma(67) : error 047: array sizes do not match, or destination array is too small
csdmwin.sma(70) : warning 213: tag mismatch
csdmwin.sma(71) : warning 213: tag mismatch
csdmwin.sma(73) : warning 204: symbol is assigned a value that is never used: "winningteam"
__________________
Quote:
367. Everyone's copyright will be broken. No exceptions.

Last edited by jonnzus; 01-31-2013 at 17:19.
jonnzus is offline
 



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 20:29.


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