Results 1 to 1 of 1
Thread: need help creating a shell game
- 09-20-2011, 12:11 AM #1
Member
- Join Date
- Aug 2011
- Posts
- 9
- Rep Power
- 0
need help creating a shell game
So we're supposed to create a game where the user is supposed to guess which shell a ball is under. If they're right they win, or they lose. Here is my code so far:
Java Code:import java.util.Scanner; public class Project3 { public static void main(String[] args) { Scanner in = new Scanner(System.in); System.out.println("What's your name?"); String name = in.next(); System.out.println("Hi " + name); System.out.println("How much money do you have?"); int money = in.nextInt(); if (money>0) { System.out.println("That's a good amount. Let's do this."); } else System.out.println("Go away deadbeat! You're not playing if you don't have money!"); } }
The problem I have right now is drawing the shells. I want it to look like this, but it's going horizontal.
---
/ \
/ o \
*it's not a perfect shell.. but hopefully you can see the right position of how it's supposed to be.
The one with the "o" is the shell which the ball is under. How do I do that?Last edited by ss1; 09-20-2011 at 12:14 AM.
Similar Threads
-
Creating a game of blackjack
By adjit in forum New To JavaReplies: 3Last Post: 04-29-2011, 02:14 PM -
Creating a flying game
By george222 in forum Java GamingReplies: 1Last Post: 02-11-2011, 10:21 AM -
Help creating a Masterminds game.
By viper98 in forum New To JavaReplies: 4Last Post: 11-09-2009, 04:13 AM -
need help creating my Tic Tac Toe game!
By bobmasta5 in forum New To JavaReplies: 6Last Post: 12-09-2008, 05:45 PM -
Creating a non-rectangular shell to simulate transparency
By Java Tip in forum SWTReplies: 0Last Post: 07-25-2008, 02:26 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks