Skip to content

Latest commit

 

History

History
43 lines (28 loc) · 950 Bytes

README.md

File metadata and controls

43 lines (28 loc) · 950 Bytes

lerp

Build Status

A vanilla lerp function, 'nuff said.

Installation

Add this to your application's shard.yml:

dependencies:
  lerp:
    github: scottyfillups/lerp

Usage

require "lerp"

include Lerp

# Prints 23
puts lerp(0, 100, 0.23)

# Prints 59
puts lerp(25, 75, 0.68).as(Int32)

The include Lerp isn't necessary, just be aware your function calls will be Lerp::lerp(...)

Contributing

  1. Fork it (https://github.com/ScottyFillups/lerp/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors