Raised This Month: $ Target: $400
 0% 

Body bug v_ primaryattack


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
batmanishere
New Member
Join Date: Jun 2019
Old 06-23-2019 , 16:20   Body bug v_ primaryattack
Reply With Quote #1

Hello guys, i have a probleme, i use v_ with submodels(body) and is work ok but on fire(+attack) body is set to 2.I want your help to stop changing body on fire, i try with postframe+preframe+etc not work.. the same probleme
Probleme: https://im3.ezgif.com/tmp/ezgif-3-b31f001e2ea2.gif
Code:
#include <amxmodx>
#include <reapi>
#include <hamsandwich>
#include <fakemeta>

public plugin_init()
{
	register_plugin("Cloak Test", "1.0", "Crazy");

	RegisterHam(Ham_Item_Deploy, "weapon_m4a1", "CKnife_Deploy")
	RegisterHam(Ham_Item_PreFrame, "weapon_m4a1", "CKnife_Deploys")
	RegisterHam(Ham_Item_PostFrame, "weapon_m4a1", "CKnife_Deploys")
	register_forward(FM_CanSkipPlayer, "CBasePlayer_CanSkip");
}

public CBasePlayer_CanSkip(this)
{
	if (!is_user_alive(this))
		return FMRES_IGNORED;

	if (get_user_weapon(this) != CSW_KNIFE)
		return FMRES_IGNORED;

	forward_return(FMV_CELL, false);
	return FMRES_OVERRIDE;
}

public CKnife_Deploys(this)
{
	set_entvar(this, var_weaponanim, 0);
	set_entvar(this, var_body, 4);
	set_entvar(this, var_skin, 4);
	set_entvar(this, var_sequence, 0);
	set_entvar(get_pdata_cbase(this, 41, 4), var_weaponanim, 0);
}
public CKnife_Deploy(this)
{
	set_entvar(this, var_weaponanim, 0);
	set_entvar(this, var_body, 4);
	set_entvar(this, var_skin, 4);
	set_entvar(this, var_sequence, 0);
	set_entvar(get_pdata_cbase(this, 41, 4), var_weaponanim, 0);
}

Last edited by batmanishere; 06-24-2019 at 03:25.
batmanishere is offline
 


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 17:26.


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