Hi i am trying to get a jet to work out the back of a ship, a ship that can rotate 360 degrees, the ship is a graphic and works fine, i am trying to code the jet so i can customise the effects for it, making it longer particles etc.
here is the code what i am basing myjet on
does anybody have an idea why the jet works for the up and down positions but not the left and right, it squishes it all into itself......not sure what i am doing wrong...
appreciate any pointers...
here is the code what i am basing myjet on
Graphics 640,480 SetBuffer BackBuffer() px=320:py=240 Repeat Cls If MouseDown(1) Or KeyHit(203) Or KeyDown(203) rot=(rot+1)Mod 360 EndIf If MouseDown(2) Or KeyHit(205) Or KeyDown(205) rot=(rot+359)Mod 360 EndIf psp=8 For i=0 To 4 Color 255,200,150 Rect px-6+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Rect px+7+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Next For i=0 To 6 Color 255,200,0 Rect px-4+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Rect px+5+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Next For i=0 To 8 Color 255,100,0 Rect px-2+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Rect px+3+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,2,6 Next For i=0 To 12 Color 255,0,0 Rect px+Sin(rot+180)*i*psp/2,py+Cos(rot+180)*i*psp/2,3,6 Next Text 10,10,"Use left and right cursor to rotate the jet stream." Flip Until KeyHit(1) End
does anybody have an idea why the jet works for the up and down positions but not the left and right, it squishes it all into itself......not sure what i am doing wrong...
appreciate any pointers...