Raised This Month: $ Target: $400
 0% 

MOVETYPE_NONE without spreading


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Gugie
Member
Join Date: Jul 2012
Old 11-11-2013 , 13:21   MOVETYPE_NONE without spreading
Reply With Quote #1

Well, i use command to set player movetype to MOVETYPE_NONE. If player didn't move, then all fine. But if he had move before i freezed him, then he get bullet spreading =( I tried to use flags FL_ONGROUND, but it didn't help =( Any another way to freeze player moving without bullet spreading?

Game: CSS

Thank you!

Last edited by Gugie; 12-09-2013 at 04:29.
Gugie is offline
Bacardi
Veteran Member
Join Date: Jan 2010
Location: mom's basement
Old 11-12-2013 , 03:08   Re: MOVETYPE_NONE without spreading
Reply With Quote #2

...change player velocity (X,Y) less than 80.0 unit or to 0.0.
PHP Code:
    SetEntPropFloat(clientProp_Send"m_vecVelocity[0]"0.0);
    
SetEntPropFloat(clientProp_Send"m_vecVelocity[1]"0.0);
    
//SetEntPropFloat(client, Prop_Send, "m_vecVelocity[2]", 0.0); // Not need change Z direction 

Last edited by Bacardi; 11-12-2013 at 03:09.
Bacardi is offline
Bimbo1
Senior Member
Join Date: Jan 2010
Location: brazil
Old 11-12-2013 , 04:40   Re: MOVETYPE_NONE without spreading
Reply With Quote #3

or change the netprop for bullet spreading.
__________________
sie sind das essen und wir sind die jäger!
Bimbo1 is offline
Gugie
Member
Join Date: Jul 2012
Old 11-12-2013 , 10:52   Re: MOVETYPE_NONE without spreading
Reply With Quote #4

Thank you! Works ^_^
Gugie is offline
Gugie
Member
Join Date: Jul 2012
Old 12-09-2013 , 04:36   Re: MOVETYPE_NONE without spreading
Reply With Quote #5

Sorry, i was too quickly when decided that this works. Well if i use m_vecVelocity, then there are no bullet spreading, but only for me. So my bullets move throw players for me and they are just missed for all another players. I tested it with my friend, he made a spray and i fired it. Then he made a screenshot. On my screen all bullets were in spray. But on my friend screenshot, my bullets were in absolutelly different places Q.Q

my friend screenshot, when on my screen all bullets in center.


Also i tried set m_fAccuracyPenalty on OnPostThinkPost but it doesn't help when u freezed =(

Last edited by Gugie; 12-09-2013 at 08:36.
Gugie is offline
Alienmario
Senior Member
Join Date: Aug 2013
Old 12-09-2013 , 08:57   Re: MOVETYPE_NONE without spreading
Reply With Quote #6

You can also freeze players with fl_frozen flag.
Alienmario is offline
Gugie
Member
Join Date: Jul 2012
Old 12-09-2013 , 09:19   Re: MOVETYPE_NONE without spreading
Reply With Quote #7

that doesn't freeze player (at least it doesn't work for me). MOVETYPE_NONE+FL_FROZEN also doesn't help =(

I think the problem that i push player and then freeze. So player is like in moving. But i need to push player before freeze, that's idea.
Gugie is offline
Gugie
Member
Join Date: Jul 2012
Old 12-10-2013 , 09:54   Re: MOVETYPE_NONE without spreading
Reply With Quote #8

Maybe there are a way to stop all player moves before freeze and then freeze?
Gugie is offline
Alienmario
Senior Member
Join Date: Aug 2013
Old 12-10-2013 , 15:25   Re: MOVETYPE_NONE without spreading
Reply With Quote #9

PHP Code:
new bool:frozen[MAXPLAYERS+1];

public 
Action:OnPlayerRunCmd(client, &Buttons, &impulseFloat:vel[3], Float:angles[3], &weapon){
    if(
frozen[client]){
        if(
Buttons IN_FORWARD || Buttons IN_BACK || Buttons IN_LEFT || Buttons IN_RIGHT){ //add more?
            
return Plugin_Handled;
        }
    }
    return 
Plugin_Continue;

http://docs.sourcemod.net/api/index....e&id=47&file=&
Alienmario is offline
Gugie
Member
Join Date: Jul 2012
Old 12-15-2013 , 08:50   Re: MOVETYPE_NONE without spreading
Reply With Quote #10

But this doesn't stop SetEntDataVector(client, offset_velocity_base, vector) or TeleportEntity(client, NULL_VECTOR, NULL_VECTOR, vector). =(
Gugie is offline
Reply



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 19:30.


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