With prokreedz.sma

21 Jun 2016, 19:46
Page 1 of 1
21 Jun 2016, 19:46(edited 21 Jun 2016, 20:06)

How to disable /savepos from spec? on prokreedz.sma
And unblock the /stuck for many stucks ?

Heelp mee! Thx

22 Jun 2016, 20:49

kz_autosavepos 0

23 Jun 2016, 10:39(edited 23 Jun 2016, 10:39)

You are using prokreedz 2.31 right? If so, replace

public SavePos(id)
{

new authid[33];


with

public SavePos(id)
{

if (get_user_team(id) != 2)
return PLUGIN_HANDLED
new authid[33];


Regarding the unlimited /stuck command, i'm also trying to find it.

29 Jun 2016, 20:23

The problem has been solved, thx 'L and DarkSideBv

29 Jun 2016, 20:26

Yes i use the prokreedz 2.31, i have new question how to put auto savepos on disconnect ? like a cosy or ankh

11 Mar 2017, 16:46

Maybe it's a bit late but I want to share the code that unstuck with much more than 2 stucks.
Code provided by Acy edited by me.

p.s. 1. tested on prokreedz 2.31
2. If you compile .sma with errors or bug just feel free to PM me.

#define MAX_CP 25
//define how many CPs you want to set as the times player can use unstuck, it's recommend to set below 50.

//replace the original code with new code
//new Float:Checkpoints[33][2][3]
new Float:Checkpoints[33][MAX_CP][3]

//new bool:g_bCpAlternate[33]
new g_bCpAlternate[33] = {-1, ...};

public CheckPoint(id)
{
.....
//--------comment original code--------------------
//pev(id, pev_origin, Checkpoints[id][g_bCpAlternate[id] ? 1 : 0])
//g_bCpAlternate[id] = !g_bCpAlternate[id]
//checknumbers[id]++
//--------add new custom code--------------------
g_bCpAlternate[id]++;
checknumbers[id]++ ;
if(g_bCpAlternate[id] == MAX_CP)//If you have CPs more than which you defined it will recount
g_bCpAlternate[id] = 0;
pev(id, pev_origin, Checkpoints[id][g_bCpAlternate[id]])
//----------------------------------------------------------
}

public GoCheck(id)
{
//comment original code
//set_pev(id, pev_origin, Checkpoints[ id ][ !g_bCpAlternate[id] ] )
//set_pev(id, pev_origin, g_player_lastcp[id])
//--------add new custom code--------------------
set_pev(id, pev_origin, Checkpoints[id][g_bCpAlternate[id]])
//----------------------------------------------------------
}

public client_putinserver(id)
{
//--------add new custom code--------------------
g_bCpAlternate[id] = -1;
}

public start_climb(id)
{
//add new custom code
g_bCpAlternate[id] = -1;

}

Page 1 of 1

Reply

Please log in to post replies.