This commit is contained in:
John 2015-05-28 21:31:56 +03:00 committed by Loudrob
parent 8c47aa0fd0
commit a1fd036cf0
2 changed files with 7 additions and 7 deletions

View file

@ -526,7 +526,6 @@ MonthlySchedule = ((7,
CatalogRentalItem(1, 2880, 1000), CatalogRentalItem(1, 2880, 1000),
CatalogRentalItem(2, 2890, 1000), CatalogRentalItem(2, 2890, 1000),
CatalogGardenStarterItem(), CatalogGardenStarterItem(),
CatalogNametagItem(100),
CatalogNametagItem(0), CatalogNametagItem(0),
CatalogClothingItem(1605, 0, True), CatalogClothingItem(1605, 0, True),
CatalogClothingItem(1602, 0, True), CatalogClothingItem(1602, 0, True),
@ -540,7 +539,8 @@ MonthlySchedule = ((7,
CatalogEmoteItem(23, True), CatalogEmoteItem(23, True),
CatalogEmoteItem(24, True), CatalogEmoteItem(24, True),
CatalogEmoteItem(25, True), CatalogEmoteItem(25, True),
CatalogEmoteItem(26, True))), CatalogEmoteItem(26, True),
CatalogNametagItem(15, True))),
(5, (5,
26, 26,
6, 6,

View file

@ -8,8 +8,9 @@ from direct.gui.DirectGui import *
class CatalogNametagItem(CatalogItem.CatalogItem): class CatalogNametagItem(CatalogItem.CatalogItem):
sequenceNumber = 0 sequenceNumber = 0
def makeNewItem(self, nametagStyle): def makeNewItem(self, nametagStyle, isSpecial = False):
self.nametagStyle = nametagStyle self.nametagStyle = nametagStyle
self.isSpecial = isSpecial
CatalogItem.CatalogItem.makeNewItem(self) CatalogItem.CatalogItem.makeNewItem(self)
def getPurchaseLimit(self): def getPurchaseLimit(self):
@ -34,9 +35,6 @@ class CatalogNametagItem(CatalogItem.CatalogItem):
return TTLocalizer.NametagTypeName return TTLocalizer.NametagTypeName
def getName(self): def getName(self):
if self.nametagStyle == 100:
name = TTLocalizer.BasicNameTag
else:
name = TTLocalizer.NametagFontNames[self.nametagStyle] name = TTLocalizer.NametagFontNames[self.nametagStyle]
if TTLocalizer.NametagReverse: if TTLocalizer.NametagReverse:
name = TTLocalizer.NametagLabel + name name = TTLocalizer.NametagLabel + name
@ -87,10 +85,12 @@ class CatalogNametagItem(CatalogItem.CatalogItem):
def decodeDatagram(self, di, versionNumber, store): def decodeDatagram(self, di, versionNumber, store):
CatalogItem.CatalogItem.decodeDatagram(self, di, versionNumber, store) CatalogItem.CatalogItem.decodeDatagram(self, di, versionNumber, store)
self.nametagStyle = di.getUint16() self.nametagStyle = di.getUint16()
self.isSpecial = di.getBool()
def encodeDatagram(self, dg, store): def encodeDatagram(self, dg, store):
CatalogItem.CatalogItem.encodeDatagram(self, dg, store) CatalogItem.CatalogItem.encodeDatagram(self, dg, store)
dg.addUint16(self.nametagStyle) dg.addUint16(self.nametagStyle)
dg.addBool(self.isSpecial)
def isGift(self): def isGift(self):
return 0 return 0