úÎYßU­M      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKL#The vector type and its operations.(c) plaimi 2015AGPL-3blubber@plaimi.netNone0 The x position.The y position. subtraction. addition. Multiply a  with a scalar. Divide a  by a scalar.Calculate the magnitude of a . Limit the magnitude of a  to a scalar.  uses a M instance to encode its data.      #The Entity type and its operations.(c) plaimi 2015AGPL-3blubber@plaimi.netNone0 The   is our hero. It is either a # that may simply be consumed by  , or it is indeed a  . A human-controlled  B has a velocity and a target position in addition to the usual  stuff.An  is a   with a position and mass.The position of the  .The mass of the  .The Blub itself.The  of the . is a quick hack to check if an  holds a  or not..Simple circle-circle-based intersect check of s based on their .A  between the passed in _s. The bigger one eats the smaller. If they are equal no one eats each other. They just hug.Let the first   the second . I.e. EAT IT! Omnomnom.  uses a M instance to encode its data. uses a M instance to encode its data. s may be ordered based on their .      The blubber world.(c) plaimi 2015AGPL-3blubber@plaimi.netNone0The  in which the  s reside.The width of the . The height of the .!The  PlayerBlob s in the  indexed on their names."The  NeutralBlob s in the .#The # of the , for randomising things.$ Try to add a  to the 8, if there is room for it. But don't try *very* hard.%Add a  ( belonging to the name in the passed in N, lest it already has a  ", in which case it's just ignored.& Delete a  ( belonging to the name in the passed in N<, lest it doesn't exist, in which case it's just ignored.' For use with !s that are not yet placed in the Ÿ, in order to check that the spot you are attempting to place them in is actually available -- i.e. that it doesn't intersect with already placed out s(( stuff between a min and a max.) The initial .* Update the   of an  based on its , and limited by its .+Update the 'position of an  based on its  . Makes sure to ( the  to the  edges.,Natural decaying of  , so as to not have too huge s..Check if any one { collides with any one other. If they do, delete them out of the recursion, and keep checking the others until every  is checked with every other./Check if any one { collides with any one other. If they do, delete them out of the recursion, and keep checking the others until every  is checked with every other.0 Given an  of a   and its id (as a N/), and a list of other such things, let the  + all the ones in the passed in the list.VIt keeps checking until there's a collision. At that point, it figures out which one blubber s which. The blubberer grows, and the blubberee is deleted. Ruthless.$If there is no collision it returns O!. If there is one, it returns a P! with two tuples -- one for each  . The survivor will be a P, the other one O.1 Given an  of a   and its id (as a N), and a list of  NeturalBlubs  s, let the     all the  NeutralbBlubs in the passed in list.bIt keeps checking until there's a collision. At that point, it returns the now rather quiute big   and the poor = it has blubbered. If there is no collision it just returns O.2%Check if the client in the passed in N is the owner of an ; if so, set its  to the passed in Qs.3 Update the . *, +, ,, and check for blubbers.4=Checks if a client has a player. If it does, then update the  of the player's . !"#$%&'()*+,-./01234 !"#$%&'()*+,-./01234 !"#$%&'()*+,-./01234 !"#$%&'()*+,-./01234%The ViewPort type and its operations.(c) plaimi 2015AGPL-3blubber@plaimi.netNone0 5A 5 is the part of the  that a client is privy to.7The absolute position of the 58The width of the 5.9The height of the 5.: The visible  PlayerBlob s in the 5.; The visible  NeutralBlob s in the 5.<Make a 5 for the passed in client's . If they don't have an ', then we'll just give them the entire  via ?. The 5 also includes the  of the player's own .=Figure out which  PlayerBlob-s are visible to a client, based on their  and .>Figure out which  NeutralBlob-s are visible to a client, based on their  and .?Make a 5 of essentieally the whole  and all its s.A5 uses a M instance to encode its data. 56789:;<=>?@A 56789:;<=>?@ 56789:;A<=>?@56789:;<=>?@A?The blubber messaging format for communicating with the server.(c) plaimi 2015AGPL-3blubber@plaimi.netNone0 B.The types of replies the blubber server sends.C#A link to the server's source code.D The latest 5 for the client.E1The types of messages the blubber server accepts.F%Ask the given IP for the source code.G)Ask to update the velocity of a player's BlubH%Ask to add a new player to the world.IAsk to part ways.JAsk to shake hands.KE uses a M instance to encode its data. BCDEFGHIJKL BCDEFGHIJ EJIHGFBDCLKBDCEJIHGFKLR      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXVYZVY[\]^_blubber-server-0.0.1Blubber.Server.VectorBlubber.Server.EntityBlubber.Server.WorldBlubber.Server.ViewPortBlubber.Server.MessageVectorVecvxvy^-^^+^^*^^/^magVec vecLimitMag$fSerializeVectorBlub PlayerBlubvelocity targetPos NeutralBlubEntityMkEntitypositionmassentityradius isNeutral intersectfiteblubber$fSerializeBlub$fSerializeEntity $fOrdEntityWorldMkWorldwidthheightplayersneutralsentropy addNeutral addPlayer delPlayer availableclamp createWorld updateVel updatePosdecayblubsplayerBlubbersneutralBlubbers playerBlubs neutralBlubs setTargetPos updateWorld handleInputViewPort MkViewPortviewPos viewWidth viewHeightvisiblePlayersvisibleNeutrals mkViewPortgetVisiblePlayers getVisibles worldViewPortviewPort$fSerializeViewPortReplySrcLinkViewMessageSrcPlsUpdateVelocity AddPlayer DisconnectConnect$fSerializeMessage$fSerializeReplycereal-0.4.1.1Data.Serialize SerializebaseGHC.BaseString Data.MaybeNothingJustghc-prim GHC.TypesDouble