major changes, not sure about all...

master
b3yond 2016-12-21 14:23:21 +01:00
parent cb3175c229
commit 46a1357525
12 changed files with 110 additions and 3413 deletions

6
.idea/vcs.xml Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

Binary file not shown.

View File

@ -43,9 +43,14 @@ class RoomEditor(object):
and can give certain fields other values, which go into Room.fielddata
or it does when its ready >.<
weird bug: Save&Quit doesnt close the window, but still returns a room object.
:todo übergebe room, nicht fields
"""
def __init__(self):
def __init__(self, fields=0):
"""
:param fields: lists of lists 30x52
"""
self.chosen = "W"
self.window = gtk.Window(gtk.WINDOW_TOPLEVEL)
self.window.connect("delete_event", self.delete_event)
@ -55,12 +60,14 @@ class RoomEditor(object):
self.box2 = gtk.HBox(False, 0)
self.menubox = gtk.VBox(False, 0)
# initialise list of lists: fields, later argument to Room()
self.fields = []
for i in range(30):
self.fields.append([])
for j in range(52):
self.fields[i].append("O")
if fields != 0:
self.fields = fields
# if no fields given, initialise list of lists: fields, later argument to Room()
else:
for i in range(30):
self.fields.append([])
for j in range(52):
self.fields[i].append("O")
# initialize dictionary: fielddata, later argument to Room()
self.fielddata = {}
self.show_fields()

Binary file not shown.

Binary file not shown.

View File

@ -1233,6 +1233,7 @@ def run_room(m, player, mission):
while running:
widgetlist = display_fields(m, player, mission)
# print "running" # debug
# print mission.current_room.fielddata # debug
events = sdl2.ext.get_events()
for event in events:
m.uiprocessor.dispatch(m.world, event)

Binary file not shown.

Binary file not shown.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,7 @@
# # # # #
# TO-DO #
# # # # #
create new mission for testing
realise game in pySDL2
enemy list system: import data from pickle file.
document how enemy, mission, item, player data is packed.
@ -8,7 +9,7 @@ change player.bitcoins back to 50
# Misc
why the fuck is fielddata in Missions test, Sewers empty? old editor version?
# Function flow

View File

@ -29,151 +29,155 @@ I5
sS'augmentations'
p12
(lp13
sS'hp'
S'wallhack'
p14
aS'cosmetic surgery'
p15
asS'hp'
p16
I98
sS'gun'
p15
p17
g0
(citems
Gun
p16
p18
g2
Ntp17
Rp18
(dp19
Ntp19
Rp20
(dp21
g7
S'No gun'
p20
sS'price'
p21
I0
sS'damage'
p22
I0
sS'grange'
sS'price'
p23
I0
sS'ap'
sS'damage'
p24
I0
sS'type'
sS'grange'
p25
S'gun'
I0
sS'ap'
p26
sS'image'
I0
sS'type'
p27
S''
S'gun'
p28
sbsS'experience'
sS'image'
p29
I100
sS'race'
S''
p30
S'Vampire'
sbsS'experience'
p31
sS'inventory'
I300
sS'race'
p32
(lp33
S'Vampire'
p33
sS'inventory'
p34
(lp35
g0
(g16
(g18
g2
Ntp34
Rp35
(dp36
Ntp36
Rp37
(dp38
g7
S'Kalaschnikow'
p37
sg21
I80
sg22
I30
sg23
I10
sg24
I100
sg25
S'gun'
p38
sg27
S'guns/kalaschnikow.gif'
p39
sg23
I80
sg24
I30
sg25
I10
sg26
I100
sg27
S'gun'
p40
sg29
S'guns/kalaschnikow.gif'
p41
sbag0
(citems
Sword
p40
p42
g2
Ntp41
Rp42
(dp43
Ntp43
Rp44
(dp45
g7
S'Mace'
p44
sS'silverdamage'
p45
I00
sg25
S'sword'
p46
sg21
I70
sg22
sS'silverdamage'
p47
I00
sg27
S'sword'
p48
sg23
I70
sg24
I70
sg26
I100
sS'critical'
p47
p49
F0.1
sS'stun'
p48
F0.5
sg27
S'swords/mace.gif'
p49
sbasS'sword'
p50
F0.5
sg29
S'swords/mace.gif'
p51
sbasS'sword'
p52
g0
(g40
(g42
g2
Ntp51
Rp52
(dp53
Ntp53
Rp54
(dp55
g7
S'Fist'
p54
sg45
p56
sg47
I00
sg25
sg27
S'sword'
p55
sg21
I0
sg22
p57
sg23
I0
sg24
I0
sg26
I50
sg47
sg49
F0.0
sg48
sg50
F0.3
sg27
g28
sg29
g30
sbsS'max_hp'
p56
p58
I98
sS'mob'
p57
p59
I5
sS'ic'
p58
p60
I0
sS'con'
p59
p61
I6
sS'id'
p60
p62
I1
sS'bitcoins'
p61
p63
I100
sb.