Raised This Month: $51 Target: $400
 12% 

[INC] Vector helpers


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
xXDeathreusXx
Veteran Member
Join Date: Mar 2013
Location: pPlayer->GetOrigin();
Old 05-29-2018 , 20:03   [INC] Vector helpers
Reply With Quote #1

Extends functionality of SourceMod vectors so you don't have to iterate through array blocks every time you want to do a simple operation on a vector. More or less self explanatory what each of them do, but there is some documentation in there

Included:
  • VectorCopy
  • VectorLerp
  • VectorMulAdd
  • VectorMin
  • VectorMax
  • VectorRand
  • VectorRotate

Some helper functions
  • AnglesNormalize - ensures an angle is within Valves tolerance
  • AngleNormalize - same, but for a single value
  • SinCos - fills in 2 floats with the sin and cosine of the provided radian
  • AngleMatrix - Given an angle, creates a rotation matrix; to be used with VectorRotate
Attached Files
File Type: inc vector_helpers.inc (5.2 KB, 292 views)
__________________
Plugins|Profile
Requests closed

I'm a smartass by nature, get used to it

Last edited by xXDeathreusXx; 08-24-2018 at 20:09. Reason: New file
xXDeathreusXx 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 15:46.


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