This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

A Python library for working with Free Rider HD Tracks.

Introduction

Free Rider HD is an online HTML5 + JS game where users can draw bike tracks, upload them to a community of players, and ride them. (Go try it out!)

When drawing a track, you can import track code from a file or from your clipboard. This library (as of now) allows you to generate that code.

Install

Fire up a terminal and run:

pip install frhdtools

You should be good to go.

Usage

Example 1: Straight Line

When you start, you’ll want to import frhdtools:

import frhdtools

Next, you should create a Track class. This will hold all of your track’s objects and code.

my_track = frhdtools.Track.Track()

Now that you’ve done that, you can add a line:

my_track.insLine(-40,50,100,50,'p')

This line goes from (-40,50) to (100,50). What is the ‘p’, you ask? That corresponds to the type of line. In this case, it means a physics line. More on types of lines later.

Now, lets generate our code:

print(my_track.genCode())
This will generate the code stored in my_track and print it to stdout.
In my case, the code was this:
-18 1i 34 1i,###

Don’t worry what the code means just yet. First let’s plug it into FRHD to see if it works.

In the Track Editor, click “Import” at the top of the editor:

Then paste in your generated code at the window that pops up.

After it loads your file, the track should look exactly like this:

Wondering about the helmet? It’s just swag.

Congratulations! You’ve just finished you first line segment. It will get easier, I promise. :wink:

Example 2: Scenery Line

Remember how I mentioned that there were different types of lines? Well here’s what they are.

In the last example we used a physics line. The rider can interact and ride on those.

In this example you’ll make a scenery line. A scenery line is a line that the rider cannot ride on. It is purely just for scenery. Also, scenery lines are gray instead of black.

It’s really easy to make a scenery line. Instead of using the code from last time:

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'p')
print(my_track.genCode())

We change the ‘p’ to an ‘s’ in my_track.insLine:

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'s')
print(my_track.genCode())

(FYI: The code should be #-18 1i 34 1i,##)

Now, when you plug the code into FRHD, you will get this:

Note: the rider will fall through the line as it does not have physics. This is normal.

Now you have made a scenery line. Great!

Example 3: Boost

In this example, you will learn how to make a boost powerup.

To start, let’s take our code from the first example:

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'p')
print(my_track.genCode())

and add my_track.insBoost(90,-10,90)

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'p')
my_track.insBoost(90,10,90)
print(my_track.genCode())

This will spawn a boost powerup at (90,10). It will be rotated 90 degrees.

** By the way, the code should look like this: -18 1i 34 1i,##B 2q a 2q,#

Plug that into FRHD, and you’re left with this:

Example 4: Bomb

In this example, you’ll learn how to spawn a bomb powerup. Bombs explode when you touch them.

So, to get started we’ll take our code from our first example and add my_track.insBomb():

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'p')
my_track.insBomb(90,10)
print(my_track.genCode())

That code makes a bomb at (90,10), which are the same coordinates from the last example.

Go ahead and put that into FRHD:

Example 5: Gravity

In this example, you’ll put a gravity powerup into a track.

Gravity powerups are pretty cool because they can switch gravity. Wow.

You know the drill. Let’s take the code from Example 1 and this time add my_track.insGravity():

import frhdtools
my_track = frhdtools.Track.Track()
my_track.insLine(-40,50,100,50,'p')
my_track.insGravity(90,10,90)
print(my_track.genCode())

Now, when you put that into FRHD, you’ll see something cool:

Honestly, I think that this is one of the coolest features in FRHD; I really apprieciate that the developers took time to put it there.

Release History

Release History

0.0.4.1

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.4.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.6

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.5

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.4

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.4b

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.3

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.3

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
frhdtools-0.0.4.1.tar.gz (5.4 kB) Copy SHA256 Checksum SHA256 Source Sep 9, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting