• Logos 35%
  • Objective-C++ 33.9%
  • Objective-C 23.9%
  • Makefile 3.2%
  • Shell 2.4%
  • Other 1.6%
Find a file
Conrad Kramer decfaf8a66 Update theos
2016-07-27 01:54:32 -07:00
Box2D Initial commit 2015-08-31 23:52:56 -07:00
layout/DEBIAN Initial commit 2015-08-31 23:52:56 -07:00
Library Make code style tolerable 2015-09-25 21:46:46 -04:00
PreferenceBundle Make code style tolerable 2015-09-25 21:46:46 -04:00
theos@8fdef7e8f5 Update theos 2016-07-27 01:54:32 -07:00
Tweak Fix settings not updating properly 2015-09-25 21:46:46 -04:00
.gitignore Initial commit 2015-08-31 23:52:56 -07:00
.gitmodules Update theos 2016-07-27 01:54:32 -07:00
get_libraries.sh Update theos 2016-07-27 01:54:32 -07:00
Makefile Initial commit 2015-08-31 23:52:56 -07:00
README.md Initial commit 2015-08-31 23:52:56 -07:00

Graviboard

This tweak brings gravity to the homescreen icons!

Graviboard is split into a number of parts:

  • Box2D - compiles the Box2D physics engine into a package that can be installed on the device.
  • Library - integrates Box2D with Apple's UIKit in a generic way.
  • Tweak - integrates the library into Apple's app launcher (SpringBoard) to add the icons to a physics simulation.
  • PreferenceBundle - allows the user to configure Graviboard from the Settings application.

The main class in the library that handles the simulation is GVPhysicsController. This class is responsible for:

  • Creating the physics world
  • Inputting information about the given UIViews into the physics world.
  • Measuring the acceleration due to gravity on the device and updating the physics world with this value.
  • Measuring the user acceleration on the device and applying a corresponding force to every object in the world.
  • Taking touch input and transforming it into hinge joints that are placed the physics world.
  • Updating the positions of the displayed UIViews at 60Hz, in sync with the framerate.

Getting Started

Prequisites

  • Xcode 5 or later
  • A jailbroken device running iOS 6 or later

Building

The first step to build the project is to clone the repository and initialize all of its submodules:

git clone git://github.com/conradev/Graviboard.git
cd Graviboard
git submodule update --init --recursive

Then we need to build libbox2d and install it on the device

cd Box2D
make package install

Then we need to install Graviboard's dependencies into theos:

cd ..
brew install xz
./get_libraries.sh

Finally, to build the project, you need only run:

make

Installing

To install this on a jailbroken device, some additional tools are needed.

The first tool is ldid, which is used for fakesigning binaries. Ryan Petrich has a build on his Github mirror:

curl -O http://cloud.github.com/downloads/rpetrich/ldid/ldid.zip
unzip ldid.zip
mv ldid theos/bin/
rm ldid.zip

To build a Debian package, dpkg is required. You can install it from Homebrew:

brew install dpkg

To build a package in the project directory, you can run:

make package

and to automatically install this package on your jailbroken device (over SSH), you can run:

make package install THEOS_DEVICE_IP=xxx.xxx.xxx.xxx

where xxx.xxx.xxx.xxx is the IP address of your device.

License

Graviboard is not available under any license for distribution.