Raised This Month: $61 Target: $400
 15% 

Solved How to use int args with handle timer function? (I can pay for solution)


Post New Thread Reply   
 
Thread Tools Display Modes
bayshades
Junior Member
Join Date: Sep 2019
Old 10-14-2020 , 15:21   Re: How to use int args with handle timer function? (I can pay for solution)
Reply With Quote #11

I just compiled your code without any problems but its not worked. !testoverlay still works.
bayshades is offline
bayshades
Junior Member
Join Date: Sep 2019
Old 10-14-2020 , 15:24   Re: How to use int args with handle timer function? (I can pay for solution)
Reply With Quote #12

Sorry but its not working. countdown not worked.
bayshades is offline
SSheriFF
AlliedModders Donor
Join Date: May 2020
Location: Israel
Old 10-14-2020 , 15:34   Re: How to use int args with handle timer function? (I can pay for solution)
Reply With Quote #13

Quote:
Originally Posted by bayshades View Post
Sorry but its not working. countdown not worked.
I had a little problem in that code. fixed it. also make sure that all the overlays are on the server.
__________________
Taking small private requests (Free) and big private requests (Paid).
Contact me via Discord: WilDick#1524

My Plugins:
SSheriFF is offline
bayshades
Junior Member
Join Date: Sep 2019
Old 10-14-2020 , 15:37   Re: How to use int args with handle timer function? (I can pay for solution)
Reply With Quote #14

PHP Code:
#include <sourcemod>
#include <sdktools>   //need for adding files to download table

#include <overlays>


//Compiler Options   //Optional, but please keep your code clean!
#pragma semicolon 1
#pragma newdecls required


int iAmmount;

public 
void OnPluginStart()
{
    
HookEvent("round_start"Event_RoundStart);
    
RegConsoleCmd("sm_testoverlay"Command_TestOverlay"Show overlay to client");
}

public 
void OnMapStart()
{
    for (
int i 111;i++)
    {
        
char path[128];
        
Format(path128"overlays/holigan_hud3/count/zombie/%d"i);
        
PrecacheDecalAnyDownload(path);   
    }
}

public 
Action Event_RoundStart(Handle event, const char[] namebool dontBroadcast)
{
    
iAmmount 10;
    
CreateTimer(20.0Timer_CountDown_TIMER_REPEAT|TIMER_FLAG_NO_MAPCHANGE);
}

public 
Action Timer_CountDown(Handle timerany data)
{
    if (
iAmmount == 0)
        return 
Plugin_Stop;
    else if(
iAmmount<=10)
    {
        
char path[128];
        
Format(path128"overlays/holigan_hud3/count/zombie/%d"iAmmount);
        
ShowOverlayAll(path1.0);
    }
     
iAmmount--;
    return 
Plugin_Continue;
}

public 
Action Command_TestOverlay(int clientint args)
{
    
ShowOverlayAll("overlays/holigan_hud3/count/zombie/10"1.0);   

    return 
Plugin_Handled;

Okay i change iAmount to 10 and changed timer to 20. Overlay 10 is working but other overlays not.

Last edited by Sillium; 10-15-2020 at 00:19. Reason: Restore to previous version.
bayshades is offline
Sillium
AlliedModders Donor
Join Date: Sep 2008
Location: Germany
Old 10-15-2020 , 00:23   Re: How to use int args with handle timer function? (I can pay for solution)
Reply With Quote #15

This is not how a community works.
If your problem was solved we are happy to hear this but blanking your thread is not the way to thank the community. Instead you should even add more info on how you solved it so others with similar problems can also find a solution.
__________________
brb, dishes have developed their own language and are talking to the garbage about overthrowing me... i must correct this

www.unterwasserpyromanen.de
Sillium 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 14:31.


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