G.Lerp

From GMod Wiki

Jump to: navigation, search
Function
Syntax Lerp( Float frac, Float start, Float end )
Where is this used?
Description:
Performs a linear interpolation between start and end. The number returned is exactly "frac" of the way between start and end.
Returns: Float
Part of Library: Global Functions
Realm: NewerShared.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=G.Lerp]G.Lerp [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Example

DescriptionLerps between the two numbers
Used onNewerShared.png
Code
print( Lerp( 0.25, 90, 0 ) );
Output67.5


See Also

Additional Notes

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox