diff options
| author | ilotterytea <iltsu@alright.party> | 2022-08-31 03:17:27 +0600 |
|---|---|---|
| committer | ilotterytea <iltsu@alright.party> | 2022-08-31 03:17:27 +0600 |
| commit | c3e365d988e3239faf0aef65cac87574b91c332d (patch) | |
| tree | 784c731ffe3818a0bf416792735c782df14ffd16 /core | |
| parent | f33399470b9fa043371ad1064068e3409db31544 (diff) | |
класс игрока
Diffstat (limited to 'core')
| -rw-r--r-- | core/src/com/ilotterytea/maxoning/player/MaxonPlayer.java | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/core/src/com/ilotterytea/maxoning/player/MaxonPlayer.java b/core/src/com/ilotterytea/maxoning/player/MaxonPlayer.java new file mode 100644 index 0000000..01353bf --- /dev/null +++ b/core/src/com/ilotterytea/maxoning/player/MaxonPlayer.java @@ -0,0 +1,26 @@ +package com.ilotterytea.maxoning.player; + +import java.io.Serializable; +import java.util.ArrayList; + +public class MaxonPlayer implements Serializable { + public float points; + public float multiplier; + public ArrayList<MaxonItem> purchasedItems; + + public MaxonPlayer() { + this.points = 0; + this.multiplier = 1.2f; + this.purchasedItems = new ArrayList<>(); + } + + public void load(MaxonPlayer player) { + if (player != null) { + this.points = player.points; + this.multiplier = player.multiplier; + + this.purchasedItems.clear(); + this.purchasedItems.addAll(player.purchasedItems); + } + } +} |
