7e6ce878 by Barry

Added skills and Partial support for feats.. Breaking change.. I really

need to start doing pull requests and branches..
1 parent 1ebbbf31
......@@ -30,6 +30,7 @@
}
}]
},
"skills" : { },
"prompt": "hp %hp mp %mp> ",
"aliases": {},
"level": 1,
......
import sys
if 'WiPy' in sys.platform:
from ucrypto import getrandbits
import network
wlan = network.WLAN(mode=network.WLAN.STA)
wlan.connect('Volley', auth=(network.WLAN.WPA2, '6198472223'))
import weemud
\ No newline at end of file
......
{"name": "test", "password": "6c76899eb15393064b4f4db94805e5862232920b", "room": "town/tavern", "abilities": {"str": 10, "dex": 23, "con": 10, "int": 12, "wis": 10, "cha": 8}, "equipment": {"finger": [null, null], "hand": [null, null], "arm": [null, null], "leg": [null, null], "foot": [null, null], "head": null, "neck": null, "back": null, "body": null, "waist": null}, "inventory": {"bag": [{"expires": 0, "inventory": {"shirt": [{"expires": 0}]}}]}, "prompt": "hp %hp mp %mp> ", "aliases": {}, "hp": 100, "mp": 10, "maxhp": 100, "maxmp": 10, "maxsta": 10, "sta": 10, "aa": "1d2", "mpr": 0.25, "star": 0.4, "weapon": null, "sp": {}, "at": {"kick": {"cost": 5, "dmg": "2d4", "desc": "You unleash a powerful kick"}}, "createstep": 7, "color_enabled": true, "over_13": true, "race": "Android", "theme": "Ace Pilot", "class": "Envoy", "abilitypoints": 0, "baseattack": 0, "fort": 0, "ref": 2, "will": 2}
\ No newline at end of file
{"name": "test", "password": "6c76899eb15393064b4f4db94805e5862232920b", "room": "town/tavern", "abilities": {"str": 10, "dex": 11, "con": 10, "int": 10, "wis": 10, "cha": 10}, "equipment": {"finger": [null, null], "hand": [null, null], "arm": [null, null], "leg": [null, null], "foot": [null, null], "head": null, "neck": null, "back": null, "body": null, "waist": null}, "inventory": {"bag": [{"expires": 0, "inventory": {"shirt": [{"expires": 0}]}}]}, "skills": {}, "prompt": "hp %hp mp %mp> ", "aliases": {}, "level": 1, "hp": 10, "mp": 10, "maxhp": 10, "maxmp": 10, "maxsta": 10, "sta": 10, "aa": "1d2", "mpr": 0.25, "star": 0.4, "weapon": null, "sp": 7, "at": {"kick": {"cost": 5, "dmg": "2d4", "desc": "You unleash a powerful kick"}}, "createstep": 7, "color_enabled": true, "over_13": true, "race": "Human", "theme": "Ace Pilot", "class": "Envoy", "abilitypoints": 12, "baseattack": 0, "fort": 0, "ref": 2, "will": 2, "maxsp": 7, "maxrp": 3, "rp": 3, "skillpoints": 9}
\ No newline at end of file
......
......@@ -3,6 +3,8 @@ import sys
if 'esp' in sys.platform:
from urandom import getrandbits
elif 'WiPy' in sys.platform:
from ucrypto import getrandbits
else:
from random import getrandbits
......@@ -15,7 +17,7 @@ codes = {'resetall': 0, 'bold': 1, 'underline': 4,
def password_hash(name, password):
if 'esp' in sys.platform:
if sys.platform in ['esp', 'WiPy']:
import uhashlib
return ''.join(['%.2x' % i for i in uhashlib.sha1(password + 'weemud' + name).digest()])
else:
......