Drawing a bullsEye to the screen. - Printable Version +- BP Forums (https://bpforums.info) +-- Forum: Archived Forums (https://bpforums.info/forumdisplay.php?fid=55) +--- Forum: Archived Forums (https://bpforums.info/forumdisplay.php?fid=56) +---- Forum: Java (https://bpforums.info/forumdisplay.php?fid=19) +---- Thread: Drawing a bullsEye to the screen. (/showthread.php?tid=408) |
Drawing a bullsEye to the screen. - brandonio21 - 10-04-2011 This was actually a school assignment, but I thought that I'd share my code with you: Code: //Exercise P4.6 - by Brandon Milton This code draws a bullseye to the screen at the location of 400,400, and grows outward. The number of rings can be edited. [attachment=0]<!-- ia0 -->javaBullseye.png<!-- ia0 -->[/attachment] Have fun! Re: Drawing a bullsEye to the screen. - luke - 06-10-2012 How does this run without a public static void main statement? Re: Drawing a bullsEye to the screen. - brandonio21 - 06-10-2012 luke Wrote:How does this run without aSince this is an applet, the paint() method runs when the application starts up. Re: Drawing a bullsEye to the screen. - baconc - 03-02-2013 this is awesome, i like sifting through the code and learning how you do this stuff so i can try to make my own shapes and what not |