Skip to content

Latest commit

Β 

History

History
69 lines (50 loc) Β· 1.43 KB

File metadata and controls

69 lines (50 loc) Β· 1.43 KB

24-Game

πŸ“ Project Structure

The application's structure is as follows (the cards folder includes all the card pictures used in the game):

24-Game/
β”œβ”€β”€ cards/
β”œβ”€β”€ security.policy
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ ExpressionParser.java
β”‚   β”œβ”€β”€ GameLobby.java
β”‚   β”œβ”€β”€ JPoker24Game.java
β”‚   β”œβ”€β”€ JPoker24GameServer.java
β”‚   β”œβ”€β”€ Leaderboard.java
β”‚   β”œβ”€β”€ MainGame.java
β”‚   β”œβ”€β”€ PlayerAuth.java
β”‚   β”œβ”€β”€ PlayerLogin.java
β”‚   β”œβ”€β”€ PlayerRegister.java
β”‚   β”œβ”€β”€ Profile.java
β”‚   └── Server.java

πŸš€ Running the Application

a. Server Side

  1. Start the Glassfish service (path may vary depending on installation):
cd glassfish5/glassfish/bin
./asadmin start-domain
  1. Set the CLASSPATH for Glassfish and MySQL Connector
    From your ./src directory:
export CLASSPATH=.:/path/to/glassfish5/glassfish/lib/gf-client.jar:/path/to/mysql-connector-j-9.2.0.jar
  1. Start the RMI registry & run the server:
rmiregistry
javac *.java
java -Djava.security.policy=../security.policy JPoker24GameServer

b. Client Side

  1. From the ./src folder, set the CLASSPATH again:
export CLASSPATH=.:/path/to/glassfish5/glassfish/lib/gf-client.jar:/path/to/mysql-connector-j-9.2.0.jar
  1. Run the client:
java -Djava.security.policy=../security.policy JPoker24Game