Raised This Month: $ Target: $400
 0% 

Where is error?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bloody806
Member
Join Date: Jun 2012
Location: Czech Republic
Old 03-13-2013 , 17:35   Where is error?
Reply With Quote #1

Hi all i need help.. This plugin i can normal compile but in game dont work. Can somebody tell me why? Please help


PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <cstrike>
#include <fun>

new timer
new boolcountdownon

const FFADE_STAYOUT 0x0004

public plugin_init()
{
    
register_plugin("Naskok","1.0","Risontek")
    
register_logevent("odpocet"2"1=Round_Start")
}

public 
odpocet(id)
{
    if(!
countdownon
    { 
        
timer 5
        countdownon 
true 
        countdown_start
(id
        if(
cs_get_user_team(id) == CS_TEAM_CT// Only For CT
        
{
        }
    }
}
public 
countdown_start(id)
{
    if(
timer >= 0
    {
        if(
timer == 0
        {
            
countdownon false 
            
if(cs_get_user_team(id) == CS_TEAM_CT// Only For CT
            
{            
                 
// screenfade
                     
message_begin(MSG_ONEget_user_msgid("ScreenFade"), _id)
                     
write_short(5// time duration in seconds
                     
write_short(5)
                     
write_short(FFADE_STAYOUT)
                     
write_byte(0// red
                     
write_byte(0// green
                     
write_byte(0// blue
                     
write_byte(255// alpha
                     
message_end()

                     
set_user_gravity(id,5000.0)
                     
set_task(5.0,"gravity",id)
           }
            return 
PLUGIN_HANDLED
}
        
set_hudmessage(02550, -1.00.3001.01.0
        
show_hudmessage(0"Anti-Furien have a head start: %i"timer
        
timer-- 
        
set_task(1.0"countdown_start")
    }
    return 
PLUGIN_CONTINUE 
}  

public 
gravity(id)
{
    
set_user_gravity(id,1.0)

__________________

Last edited by bloody806; 03-13-2013 at 17:36.
bloody806 is offline
Send a message via Skype™ to bloody806
Torge
Veteran Member
Join Date: Oct 2011
Old 03-13-2013 , 17:52   Re: Where is error?
Reply With Quote #2

As far as I know, "logevent" has no parameters.
Torge is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-14-2013 , 02:15   Re: Where is error?
Reply With Quote #3

Code is full of errors.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
simanovich
AlliedModders Donor
Join Date: Jun 2012
Location: Israel
Old 03-14-2013 , 03:52   Re: Where is error?
Reply With Quote #4

dafuq lol

All code is wrong
__________________

Last edited by simanovich; 03-14-2013 at 03:53.
simanovich is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-14-2013 , 04:41   Re: Where is error?
Reply With Quote #5

Code fixed.

Spoiler


You may want to use this though :

Spoiler
__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 03-14-2013 at 04:50.
ConnorMcLeod is offline
bloody806
Member
Join Date: Jun 2012
Location: Czech Republic
Old 03-14-2013 , 10:48   Re: Where is error?
Reply With Quote #6

Very thanks ConnorMcLeod
__________________
bloody806 is offline
Send a message via Skype™ to bloody806
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 21:44.


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