Skip to content

Commit

Permalink
Added README.md to project file and added Box2D information to the RE…
Browse files Browse the repository at this point in the history
…ADME.
  • Loading branch information
pjvds committed Apr 1, 2011
1 parent beb8daf commit ce2f434
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 2 deletions.
32 changes: 31 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,37 @@ The following stuff is used to create this Pong implementation for IOS:
* Box2D
* Freetime in an hotel in Rotterdam

# What you need to know about Box2D
Box2D works with several fundamental objects. We briefly define these objects here and more details are given later in this document.

## world
A physics world is a collection of bodies, fixtures, and constraints that interact together. Box2D supports the creation of multiple worlds, but this is usually not necessary or desirable.

## shape
A 2D geometrical object, such as a circle or polygon.

## rigid body
A chunk of matter that is so strong that the distance between any two bits of matter on the chunk is completely constant. They are hard like a diamond. In the following discussion we use body interchangeably with rigid body.

## fixture
A fixture binds a shape to a body and adds material properties such as density, friction, and restitution.

## constraint
A constraint is a physical connection that removes degrees of freedom from bodies. In 2D a body has 3 degrees of freedom (two translation coordinates and one rotation coordinate). If we take a body and pin it to the wall (like a pendulum) we have constrained the body to the wall. At this point the body can only rotate about the pin, so the constraint has removed 2 degrees of freedom.

## contact constraint
A special constraint designed to prevent penetration of rigid bodies and to simulate friction and restitution. You do not create contact constraints; they are created automatically by Box2D.

## joint
This is a constraint used to hold two or more bodies together. Box2D supports several joint types: revolute, prismatic, distance, and more. Some joints may have limits and motors.

## joint limit
A joint limit restricts the range of motion of a joint. For example, the human elbow only allows a certain range of angles.

## joint motor
A joint motor drives the motion of the connected bodies according to the joint's degrees of freedom. For example, you can use a motor to drive the rotation of an elbow.

# Code Fest
I created this for the Devnology [Code Fest][1]. using XCode, ObjC and the Cocos2D Box2d framework.

[1]: http://devnology.nl/en/meetings/details/33-the-legacy-code-fest
[1]: http://devnology.nl/en/meetings/details/33-the-legacy-code-fest
6 changes: 5 additions & 1 deletion iPong.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@
50F4144910692EE7002A0D5E /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 50F4144410692EE7002A0D5E /* Default.png */; };
50F4144A10692EE7002A0D5E /* fps_images.png in Resources */ = {isa = PBXBuildFile; fileRef = 50F4144510692EE7002A0D5E /* fps_images.png */; };
50F4144B10692EE7002A0D5E /* Icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 50F4144610692EE7002A0D5E /* Icon.png */; };
DA395A5D1345BD2F00A254C1 /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = DA395A5C1345BD2F00A254C1 /* README.md */; };
DAC94A991337F85A005F58F2 /* Ball.png in Resources */ = {isa = PBXBuildFile; fileRef = DAC94A981337F85A005F58F2 /* Ball.png */; };
DAE725D213427B4D0028394E /* whitedot.png in Resources */ = {isa = PBXBuildFile; fileRef = DAE725D113427B4D0028394E /* whitedot.png */; };
DC6640030F83B3EA000B3E49 /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DC6640020F83B3EA000B3E49 /* AudioToolbox.framework */; };
Expand Down Expand Up @@ -352,7 +353,7 @@
50674862107A3B340090963A /* ZAttributedStringPrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZAttributedStringPrivate.h; sourceTree = "<group>"; };
506EDB87102F4C4000A389B3 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; };
506EDBA4102F4C9F00A389B3 /* AVFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AVFoundation.framework; path = System/Library/Frameworks/AVFoundation.framework; sourceTree = SDKROOT; };
506EDC2F102F528A00A389B3 /* iPongLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; path = iPongLayer.h; sourceTree = "<group>"; };
506EDC2F102F528A00A389B3 /* iPongLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iPongLayer.h; sourceTree = "<group>"; };
506EDC30102F528A00A389B3 /* iPongLayer.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = iPongLayer.mm; sourceTree = "<group>"; };
506EE05E10304ED200A389B3 /* libcocos2d libraries.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libcocos2d libraries.a"; sourceTree = BUILT_PRODUCTS_DIR; };
507ED65311C638E2002ED3FC /* CDAudioManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDAudioManager.h; sourceTree = "<group>"; };
Expand Down Expand Up @@ -467,6 +468,7 @@
50F4144510692EE7002A0D5E /* fps_images.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = fps_images.png; sourceTree = "<group>"; };
50F4144610692EE7002A0D5E /* Icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Icon.png; sourceTree = "<group>"; };
50F4144710692EE7002A0D5E /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
DA395A5C1345BD2F00A254C1 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README.md; sourceTree = "<group>"; };
DAC94A981337F85A005F58F2 /* Ball.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Ball.png; sourceTree = "<group>"; };
DAE725D113427B4D0028394E /* whitedot.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = whitedot.png; sourceTree = "<group>"; };
DC6640020F83B3EA000B3E49 /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; };
Expand Down Expand Up @@ -701,6 +703,7 @@
29B97314FDCFA39411CA2CEA /* CustomTemplate */ = {
isa = PBXGroup;
children = (
DA395A5C1345BD2F00A254C1 /* README.md */,
504DFC7310AF1758006D82FE /* LICENSE.cocos2d */,
504DFC7410AF1758006D82FE /* LICENSE.cocosdenshion */,
E0C5506C11FA3ABC00B9E4CB /* LICENSE.box2d */,
Expand Down Expand Up @@ -1450,6 +1453,7 @@
E02BBA11126CC29D006E46A2 /* iTunesArtwork in Resources */,
DAC94A991337F85A005F58F2 /* Ball.png in Resources */,
DAE725D213427B4D0028394E /* whitedot.png in Resources */,
DA395A5D1345BD2F00A254C1 /* README.md in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down

0 comments on commit ce2f434

Please sign in to comment.