Raised This Month: $ Target: $400
 0% 

Permanent Superjump?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 03-19-2009 , 13:57   Re: Permanent Superjump?
Reply With Quote #6

wont work, ts_givepwup doesn't work. You have to createpwup then set its origin UNDER the person then they move into it. that function has never worked sadily,
Code:
static cell AMX_NATIVE_CALL give_pwup(AMX *amx, cell *params)
{ // index,pwupentindex
	edict_t* pent = INDEXENT(params[2]);
	if ( FNullEnt( pent ) || strcmp("ts_powerup",STRING(pent->v.classname))!=0 ){
		return 0;
	}
	
	int id = params[1];
	if (id<1 || id>gpGlobals->maxClients)
	{ 
		MF_LogError(amx, AMX_ERR_NATIVE, "Invalid player %d", id);
		return 0;
	}
	CPlayer *pPlayer = GET_PLAYER_POINTER_I(id);
	if (!pPlayer->ingame || !pPlayer->IsAlive())
	{
		MF_LogError(amx, AMX_ERR_NATIVE, "Player %d is not ingame.", id);
		return 0;
	}

	pent->v.origin = pPlayer->pEdict->v.origin;

	MDLL_Touch(pent, pPlayer->pEdict);

	REMOVE_ENTITY(pent);

	return 1;
}

Last edited by Styles; 03-19-2009 at 14:01.
Styles is offline
Send a message via AIM to Styles
 



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 08:58.


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