diff options
author | Jesusaves <cpntb1@ymail.com> | 2020-12-31 11:19:40 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2020-12-31 11:19:40 -0300 |
commit | 636f7ba1cea6ef8b6c24d936d29f7df593b32ff9 (patch) | |
tree | dd404b7b4a1c7c159e5f90fab927489b2281f0b7 | |
parent | 7d904dedd780cc41a7cb283134026917ca068e84 (diff) | |
download | server-636f7ba1cea6ef8b6c24d936d29f7df593b32ff9.tar.gz server-636f7ba1cea6ef8b6c24d936d29f7df593b32ff9.tar.bz2 server-636f7ba1cea6ef8b6c24d936d29f7df593b32ff9.tar.xz server-636f7ba1cea6ef8b6c24d936d29f7df593b32ff9.zip |
Fix typos and a bug of a swapped max and min function
-rw-r--r-- | consts.py | 4 | ||||
-rw-r--r-- | player.py | 2 | ||||
-rw-r--r-- | protocol.py | 4 | ||||
-rw-r--r-- | security.py | 4 | ||||
-rwxr-xr-x | server.py | 4 |
5 files changed, 9 insertions, 9 deletions
@@ -1,4 +1,4 @@ -######################################################################################## +################################################################################# # This file is part of Spheres. # Copyright (C) 2019 Jesusalva @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -######################################################################################## +################################################################################# # Constants Module # Elements @@ -227,7 +227,7 @@ def check_rank_up(token): Player[token]["max_exp"]=exp_to_lvlup(Player[token]["level"]) update_ap(token, Player[token]["max_ap"]-Player[token]["ap"]) # Sanitize - Player[token]["exp"]=max(Player[token]["exp"], exp_to_lvlup(Player[token]["level"])) + Player[token]["exp"]=min(Player[token]["exp"], exp_to_lvlup(Player[token]["level"])) return rs diff --git a/protocol.py b/protocol.py index f6a2905..4ee50c3 100644 --- a/protocol.py +++ b/protocol.py @@ -1,4 +1,4 @@ -######################################################################################## +################################################################################# # This file is part of Spheres. # Copyright (C) 2019 Jesusalva @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -######################################################################################## +################################################################################# # Protocol Module # Parses packets import utils diff --git a/security.py b/security.py index 8383fae..6a51f79 100644 --- a/security.py +++ b/security.py @@ -1,4 +1,4 @@ -######################################################################################## +################################################################################# # This file is part of Spheres. # Copyright (C) 2019 Jesusalva @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -######################################################################################## +################################################################################# # Adds an extra layer of security to the server # Really basic stuff, still better than nothing, though import threading, time, traceback @@ -1,5 +1,5 @@ #!/usr/bin/python3 -######################################################################################## +################################################################################# # This file is part of Mana Spheres. # Copyright (C) 2020 Jesusalva @@ -15,7 +15,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -######################################################################################## +################################################################################# ## Global Modules import threading, time, json, syslog |