Raised This Month: $ Target: $400
 0% 

Bad Load Angles


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
minato
Senior Member
Join Date: May 2010
Location: Rosario
Old 07-03-2010 , 13:39   Bad Load Angles
Reply With Quote #1

Hello, good as he says the title to all on having loaded the angles the entity loads them correctly loads of side and not abreast since it was guarded

Image:


Code:

PHP Code:
SaveOriginsid )
{
    if( 
file_existsgConfigFile ) )
        
delete_filegConfigFile );

    new 
iFile fopengConfigFile"wt" );

    if( !
iFile ) return;

    new 
Float:vOrigin], iEntity
    
new Float:iAngles]  

    while( ( 
iEntity find_ent_by_classiEntity_CLASS) ) > 
    {
        
pev(iEntitypev_originvOrigin );
        
pev(iEntitypev_anglesiAngles);
    

        
fprintfiFile"%f %f %f | Origins - %f %f %f | Angles^n"vOrigin], vOrigin], vOrigin],iAngles], iAngles], iAngles] );
    }
    
client_print(id,print_chat,"[EM] Save Succes!")
    
    
fcloseiFile );
}
LoadOrigins() 
{
    new 
iFile fopengConfigFile"rt" );

    if( !
iFile ) return;
    
    new 
Float:iAngles],ix16 ], iy16 ], iz16 ]
    new 
Float:vOrigin], x16 ], y16 ], z16 ],szDatasizeof) + sizeof) + sizeof) + sizeofix ) + sizeofiy ) + sizeofiz ) + ];
    while( !
feofiFile ) ) 
    {
        
fgetsiFileszDatacharsmaxszData ) );
        
trimszData );
        
        if( !
szData] ) continue;
        
        
parseszDatax15y15z15ix15iy15iz15);
        
vOrigin] = str_to_float);
        
vOrigin] = str_to_float);
        
vOrigin] = str_to_float);
        
iAngles] = str_to_floatix );
        
iAngles] = str_to_floatiy );
        
iAngles] = str_to_floatiz );
        
        
make_ent(vOrigin,iAngles)
        
    }
    
    
fcloseiFile );

minato is offline
Send a message via MSN to minato
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 07-03-2010 , 13:53   Re: Bad Load Angles
Reply With Quote #2

try this:
PHP Code:
SaveOriginsid )
{
    if( 
file_existsgConfigFile ) )
        
delete_filegConfigFile );

    new 
iFile fopengConfigFile"wt" );

    if( !
iFile ) return;

    new 
Float:vOrigin], iEntity
    
new Float:iAngles]  

    while( ( 
iEntity find_ent_by_classiEntity_CLASS) ) > 
    {
        
pev(iEntitypev_originvOrigin );
        
pev(iEntitypev_anglesiAngles);
    

        
fprintfiFile"%f %f %f %f %f %f^n"vOrigin], vOrigin], vOrigin],iAngles], iAngles], iAngles] );
    }
    
client_print(id,print_chat,"[EM] Save Succes!")
    
    
fcloseiFile );
}
LoadOrigins() 
{
    new 
iFile fopengConfigFile"rt" );

    if( !
iFile ) return;
    
    new 
Float:iAngles],ix16 ], iy16 ], iz16 ]
    new 
Float:vOrigin], x16 ], y16 ], z16 ],szDatasizeof) + sizeof) + sizeof) + sizeofix ) + sizeofiy ) + sizeofiz ) + ];
    while( !
feofiFile ) ) 
    {
        
fgetsiFileszDatacharsmaxszData ) );
        
trimszData );
        
        if( !
szData] ) continue;
        
        
parseszDatax15y15z15ix15iy15iz15);
        
vOrigin] = str_to_float);
        
vOrigin] = str_to_float);
        
vOrigin] = str_to_float);
        
iAngles] = str_to_floatix );
        
iAngles] = str_to_floatiy );
        
iAngles] = str_to_floatiz );
        
        
make_ent(vOrigin,iAngles)
        
    }
    
    
fcloseiFile );

__________________
Impossible is Nothing
Sylwester is offline
minato
Senior Member
Join Date: May 2010
Location: Rosario
Old 07-03-2010 , 14:33   Re: Bad Load Angles
Reply With Quote #3

Sylwester@ Thank you for your help, now it works correctly
minato is offline
Send a message via MSN to minato
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 07:11.


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