Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Players can plant the bomb during pauses #105

Open
Useless39rus opened this issue Jun 24, 2017 · 2 comments
Open

Players can plant the bomb during pauses #105

Useless39rus opened this issue Jun 24, 2017 · 2 comments

Comments

@Useless39rus
Copy link

Useless39rus commented Jun 24, 2017

During a pause, I can put a bomb.

Expected behavior

The bomb should not be installed during a pause.

Actual behavior

During a pause, I can put a bomb.

Steps to reproduce

  • Plugin version: csgo-retakes build 131
  • Sourcemod version: Sourcemod 1.8 build 6014

P.S. Sorry for my English.

@supaflyENJOY
Copy link

supaflyENJOY commented Oct 28, 2017

You can use SDKHook WeaponCanSwitchTo to block players ability to use bomb
Something like this:

SDKHook(client , SDKHook_WeaponCanSwitchTo, CanUse_Func);
public Action CanUse_Func(int client, int ent)
{
	char weapon[20]; 
	if (isPaused() && isFreezeTime() && GetEntityClassname(ent, weapon, sizeof(weapon)) && StrEqual(weapon, "weapon_c4"))
        return Plugin_Handled;
	
    return Plugin_Continue;
} 

But, i think, could be clearer way, cuz you also need to change everyone weapon to something else, if player using bomb at this moment

@splewis splewis changed the title During a pause, I can put a bomb. Players can plant the bomb during pauses Oct 7, 2018
@borzaka
Copy link
Contributor

borzaka commented Sep 3, 2019

Or you can just disable voting, hence disable pausing with sv_allow_votes 0.
Put it to cfg/sourcemod/retakes/retakes_game.cfg

I don't think you need to pause a retake anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants