Skip to content
Snippets Groups Projects
Commit 54217379 authored by Jack Thomas's avatar Jack Thomas
Browse files

submission-4

parent 084e5fc9
No related branches found
No related tags found
No related merge requests found
......@@ -79,8 +79,8 @@ public class Property {
public void buyProperty(final Players player, final Property property){
player.setBalance(-property.value); // Charges player the property's value.
property.owner = player; // Sets the player as the property object's owner.
System.out.println("You have purchased the property! You now have £" + player.getPlayerBalance() + " + " + player.getPlayerProperties() + " properties.");
player.setPlayerProperties(1); // Increases player's number of properties owned.
System.out.println("You have purchased the property! You now have £" + player.getPlayerBalance() + " + " + player.getPlayerProperties() + " properties.");
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment