Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- elif self.isFesta:
- maplist = []
- dbcur.execute('select code from mapeditor where perma = 2')
- rrfRows = dbcur.fetchall()
- if rrfRows is None:
- pass
- else:
- for rrf in rrfRows:
- maplist.append(rrf[0])
- if len(maplist)>=1:
- runthismap = random.choice(maplist)
- else:
- runthismap = ""
- if len(maplist)>=2:
- while runthismap == self.ISCM:
- runthismap = random.choice(maplist)
- if runthismap=="":
- self.ISCM = -1
- return 0
- else:
- mapcode = int(runthismap)
- mapname = self.server.getMapName(mapcode)
- mapxml = self.server.getMapXML(mapcode)
- yesvotes = int(self.server.getMapYesVotes(mapcode))
- novotes = int(self.server.getMapNoVotes(mapcode))
- perma = int(self.server.getMapPerma(mapcode))
- mapnoexist = int(self.server.getMapDel(mapcode))
- self.ISCM = mapcode
- self.ISCMdata = [mapcode, mapname, mapxml, yesvotes, novotes, perma, mapnoexist]
- return "-1"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement