youmoveaway,thenshallowsout.Understandingthis
formulaiskeytoplayingKerbalSpaceProgram,inwhich
yousendlittlegreenmentovisitotherplanetsina
kookyyetunforgivingapproximationofoursolar
system.“It’sthethingthatmakesorbitswork,”Falanghe
says.“Ifyoudon’taddthatorbitswilllooklike...well,
theywon’tlooklikecircles.”Indeed,mostKerbal
spaceflightslooklikecraters.
IfKerbalstickstothetextbooksonthiscount,it
‘cheats’onotherfronts.Inparticular,itsidestepsthe
so-called’n-body’problem,wherebyeveryplanetarymass
inagroupexertsagravitationalpulloneveryotherbody
simultaneously.“KSPdoessomethingthatisnotentirely
realisticwhichissometimescalledpatchedconic
approximation,whichisjustafancywayofsayingthatwe
switchgravitysourceswheneveryougetcloseenoughto
anotherone.Whenyoucrossintothe‘sphereofinfluence’
ofthemoon,thesourcesswitch,andnowyou’reonly
affected by gravity from the moon.”
Treating gravity as a strictly two-way affair makes for a
more stable and predictable simulation, which is vital
given that missions in Kerbal can take several in-game
years. It means that the simulation doesn’t have to
recalculate gravity ‘step by step’; indeed, the game can
switch mid-spaceflight to a “deterministic” means of
calculating movement without causing discrepancies. “We
used to call it the rails system because the spacecraft was
on rails, and it basically meant that we could freeze all
physics, and just carry things through space.” The
horizon,youhavetofigureoutwhereyouareinrelation
totheplanetandapplyforcetowardsthecentre.”
Astohowmuchforceyoushouldapply,most
developersandastrophysicistsfollowIsaacNewton’s
inversesquarelawofgravity,whichdictatesthatan
object’sgravityisstrongupcloseanddropsoffrapidlyas
andgravitybecomesevenmoreofa
riddle.“The
definitionofdownisn’tdownanymore,”
saysFelipe
Falanghe,creatorofKerbalSpaceProgram
move .“Youcan’tjust
thingstowardsthebottomofthescreen
orthe
SQUARINGTHECIRCLE
Expandtheplayablespace
toencompassanactualplanet,
specificmovementtrajectory.
pillars,he’llhave
clones.”Assuch,
switchesoffgravity FryingJellysometimes
entirelywhenit
wantstoadda
longlegs,he’ll
beagrasshopper
jumpingonto
broken
mechanic
thatthe
playeruses
- he’ll be a cart, he’ll have
Pachniewski. “And each time, there’s a different
grotesque ways,” says Frying Jelly’s founder Pawel
nightmare, where he’s transforming in weird and
thosethatadheresternlytothesciencestruggleto
portraytheideasputforwardinAlbertEinstein’s
theoryofgeneralrelativity.
UPWARDLYMOBILE
BeforewegettoEinstein,however,let’stalkMario.
Workingouthowtomakeacharacterfallinaplatformer
isoneofgamedevelopment’sbread-and-butter
challenges.Itsoundssimpleenough:yousubtracta
certainverticaldistancefromthecharactereveryframe
unlessthere’ssomethingintheway.Butgettingaleaping
characterto‘feel’rightcantakemonthsofwork,because
everydaygravityisgenerallymoreinconvenientthan
enjoyable.Tomakeitsingina
videogame,youhavetofigureout
howandwhentobreaktherules.
“Ifyouapplygravityontopofa
normaljump,you’regoingtoget
thisparabolashape,”explains
FryingJelly’sEricStryczek,oneof
themindsbehindthedreamyyet
ferocious 99 Fails.“It’sperfect.
[But]itactuallyfeelsreallyterrible
asajump.SowhatMariodidallthe
waybackontheNintendo
EntertainmentSystemwashave
thissortofextrabehaviour–when
you’refalling,velocitygetsexponential.Soyousortof
goup,stayintheairforawhile,andthenyouget
suckedrightbackdownreallyquickly.”
TheequationforhowfastobjectsfallonEarthis
minus9.81metrespersecondsquared–manythird-party
gameengineslikeUnitytreatthisastheroughdefaultfor
theirphysicssystems.ButasStryczekgoeson,“Itfeels
reallyfloatytohaveavaluelikethat.Becausein
platformers,wetendtojumpreallyhigh.Whatalotof
beginnersgetwrongisthattheydon’tmesswiththis
value–you really need to have that snappy feeling.”
In 99 Fails, things are complicated by the protagonist
Zeebo’s habit of changing shape. “Zeebo has this recurring
withrealityoutofnecessityorsimply
inthenameoffun.
Theyaretheirownlittlebespokeuniverses
- and even
need a PhD to understand, but most games compromise
visualising equations and
phenomena
you’dotherwise
space
sims. These games can be a useful means of
theJenga-esque launch vehicle physics of full-blown 3D
medium’s birth, from the geometric landslides of
Tetris to
Videogames have been wrestling with gravity since the
Gravity
FEATURE
YOU HAVE
TO FIGURE OUT
HOW AND WHEN
TO BREAK
THE RULES