Raised This Month: $ Target: $400
 0% 

pass origin through functions


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 03-06-2009 , 09:45   pass origin through functions
Reply With Quote #1

Hello again :}

I cannot get a function to receive origins, I get compile "invalid tag" warnings.

Something like this:
Code:
public function(id)
{
       static Float:fOrigin[3], origin[3]
       get_user_origin(id, fOrigin)
 
       origin[0] = floatround(fOrigin[0])
       origin[1] = floatround(fOrigin[1])
       origin[2] = floatround(fOrigin[2])
 
       do_something(origin)
}
 
public do_something(origin[3])
{
        /* blablabla spawn something at origin */
}
__________________
Hunter-Digital is offline
 



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 08:55.


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