Raised This Month: $ Target: $400
 0% 

Aiming vector


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
USvER
Junior Member
Join Date: Nov 2006
Location: Ukraine, Kyiv
Old 12-18-2007 , 05:42   Aiming vector
Reply With Quote #1

I want to save and change aiming vector but something is obviously wrong...
An inversion goes at Y and -Y is lost...

PHP Code:
#include <amxmodx>
#include <fakemeta>

/////////////////////////////////////////////////////////////////////////////////////
//////////////////////GLOBALS////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////

#define MAX_FRAMES 500
new demo_recording 0
new demo_playing 0
new Float:demo_data[MAX_FRAMES][3]
new 
demo_curentframe 0

/////////////////////////////////////////////////////////////////////////////////////
////////////////////////MAIN/////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////

public plugin_init(){
    
register_plugin("Megaplugin""0.1b""[UA] USvER")

    
register_concmd("demo_record""demo_record"ADMIN_KICK"")
    
register_concmd("demo_play""demo_play"ADMIN_KICK"")

    
register_forward(FM_StartFrame,"demo_frame"0)
}

/////////////////////////////////////////////////////////////////////////////////////

public demo_record(idlevelcid){
    if (!
demo_playing)demo_recording 1
    
return PLUGIN_HANDLED
}

/////////////////////////////////////////////////////////////////////////////////////

public demo_play(idlevelcid){
    if (!
demo_recording)demo_playing 1
    
return PLUGIN_HANDLED
}

/////////////////////////////////////////////////////////////////////////////////////

public demo_frame(){
    new 
id get_user_index("USvER")
    if(
demo_recording){
        
pev(idpev_angles,demo_data[demo_curentframe])
        ++
demo_curentframe
        
if(demo_curentframe == MAX_FRAMES){
            
demo_curentframe 0
            demo_recording 
0
        
}
    }

    if(
demo_playing){
        
set_pev(idpev_anglesdemo_data[demo_curentframe])
        
set_pev(idpev_fixangle1)
        ++
demo_curentframe


        
if(demo_curentframe == MAX_FRAMES){
            
demo_curentframe 0
            demo_playing 
0
        
}
    }

    return 
FMRES_OVERRIDE

Please explain to me these variables
pev_v_engle
pev_engles
pev_origin
pev_velocity

tnx
USvER is offline
Send a message via ICQ to USvER
 


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 11:02.


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