Type cannonball Field x Field y Field cubeEnd Type Graphics3D 640,480,16,2SetBuffer(BackBuffer())cam=CreateCamera()MoveEntity cam,35,10,-70c.cannonball=New cannonballccube=CreateSphere()While True If KeyHit(57) c.cannonball=New cannonball:ccube=CreateSphere():cx=0:cy=0 For c.cannonball=Each cannonballcy=(-0.01347*cx*cx+0.9325*cx+5.5)*2 cx=cx+1 PositionEntity ccube,cx,cy,0 Next RenderWorld Flip Wend
Type cannonball Field x Field y Field cubeEnd Type Graphics3D 640,480,32,2SetBuffer(BackBuffer())cam=CreateCamera()MoveEntity cam,35,10,-70c.cannonball=New cannonballccube=CreateSphere()While True If KeyHit(57) c.cannonball=New cannonball:ccube=CreateSphere():cx=0:cy=0 p=0 For c.cannonball=Each cannonball p=p+1 cy=(-0.01347*cx*cx+0.9325*cx+5.5)*2 cx=cx+1 PositionEntity ccube,cx,cy,0 If cy<0 FreeEntity ccube Delete c EndIf Next RenderWorld Text 0,0,"Active Cannonballs="+p Flip (1) Wend