Browse Source

Tweak place code and response messages

Skylar Ittner 2 years ago
parent
commit
affc1d863b
3 changed files with 4 additions and 4 deletions
  1. 1
    1
      attackplace.php
  2. 1
    1
      claimplace.php
  3. 2
    2
      refillplace.php

+ 1
- 1
attackplace.php View File

@@ -52,7 +52,7 @@ $damage = pow(floor($user['level']), 0.5) * 4 * $type_mod * $terrain_mod * $weat
52 52
 //$damage = 2 * $userdrain * $TYPE_GRID[$user['teamid']][$place['teamid']];
53 53
 // Check if action possible
54 54
 if ($user['energy'] < $userdrain) {
55
-    sendError("Not enough life left!", true);
55
+    sendError("No life left!", true);
56 56
 }
57 57
 
58 58
 // Calculate resulting user HP

+ 1
- 1
claimplace.php View File

@@ -25,7 +25,7 @@ $userdrain = 5 * floor($user['level']);
25 25
 $userhp = $user['energy'] - $userdrain;
26 26
 // Check if action possible
27 27
 if ($userhp < 0) {
28
-    sendError("Not enough life left!", true);
28
+    sendError("No life left!", true);
29 29
 }
30 30
 
31 31
 // Update the user's health and level

+ 2
- 2
refillplace.php View File

@@ -19,13 +19,13 @@ if ($place['currentlife'] == 100) {
19 19
     sendError("Full!", true);
20 20
 }
21 21
 
22
-$userdrain = 5 * floor($user['level']);
22
+$userdrain = 2 * floor($user['level']);
23 23
 
24 24
 // Calculate resulting user HP
25 25
 $userhp = $user['energy'] - $userdrain;
26 26
 // Check if action possible
27 27
 if ($userhp < 0) {
28
-    sendError("No life!", true);
28
+    sendError("No life left!", true);
29 29
 }
30 30
 
31 31
 // Update the user's health and level

Loading…
Cancel
Save