Raised This Month: $ Target: $400
 0% 

Problem with pev_view_ofs


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 02-10-2010 , 03:11   Problem with pev_view_ofs
Reply With Quote #1

Hi,

i wanted to catch the origins of users view offset(Aim origins) to spawn my sprite, but like ever i have a problem

the offset/origins are not correct.

PHP Code:
public ClientCommand_CreateMagic ( const Player, const Level, const Cid )
{
    if ( !
cmd_accessPlayerLevelCid) )
    {
        return 
PLUGIN_HANDLED;
    }
    
    new 
Float:Origin[3];
    new 
Entity;
    
    
pev(Player,pev_v_angle,Origin)
    
    if ( ( 
Entity create_entity"info_target" ) ) )
    {
        
set_pevEntitypev_classnamegMagicBallClassname );
        
        
        
engfuncEngFunc_SetSize  EntityFloat:{ -311.0, -1.0, -1.0 }, Float:{ 311.01.01.0 } );
        
engfuncEngFunc_SetOriginEntityOrigin );
        
        
set_pevEntitypev_effectsEF_BRIGHTFIELD );
        
set_pevEntitypev_solidSOLID_BBOX );
        
set_pevEntitypev_movetypeMOVETYPE_TOSS );
        
set_pevEntitypev_ownerPlayer );
        
set_pevEntitypev_nextthinkget_gametime() + 0.1 );
    }
    
    return 
PLUGIN_HANDLED_MAIN;

&& when i use the command to spawn the ball, i got crashes no error, nothing in log. my game will be freezed.
Attached Thumbnails
Click image for larger version

Name:	1.jpg
Views:	727
Size:	97.4 KB
ID:	59442  
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
 



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


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