Skip to content

wrigjl/balls

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 

Repository files navigation

This is a server for a MMORPG. The players get to be characters in the audience of their favorite music artistic while a concert is happening. Suddenly, some number of beach balls are tossed into the audience. The players might catch them, they might throw them back... who knows!

Much excitement abounds!

Ok, for the RESTful API... an id is a 12 character hexidecimal ascii string, e.g. feedbeefcafe, babb1ebabb1e, or f001de7ec7ed.

/poll/[id]: poll the server to determine whether you currently have a ball

/toss/[id]: toss the ball (if you have it)

Each of these endpoints returns a json object like this:

{
	"User":"001122334455",
	"Score":0,
	"Err":"",
	"Hasball":true
}

User is the id passed to the API, Score is the user's current score (more later), Err is any error message (usually empty), and Hasball is an indicator of whether this user currently has a ball.

To score, a user must toss the ball after having realized they have it, but they must do so before the ball expires (currently 2 minutes). Users are expected to poll once per minute. The number of balls in circulation is kept to approximately 1 per 5 active users. A user is active if they have interacted with the API in the past 3 minutes.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published