当前位置: 首页>>代码示例>>Python>>正文


Python DistributedSmoothNode.__init__方法代码示例

本文整理汇总了Python中direct.distributed.DistributedSmoothNode.DistributedSmoothNode.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python DistributedSmoothNode.__init__方法的具体用法?Python DistributedSmoothNode.__init__怎么用?Python DistributedSmoothNode.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在direct.distributed.DistributedSmoothNode.DistributedSmoothNode的用法示例。


在下文中一共展示了DistributedSmoothNode.__init__方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
 def __init__(self, cr):
     self.cr = cr
     Char.Char.__init__(self)
     DistributedSmoothNode.__init__(self, cr)
     self.name = ''
     self.anim = ''
     self.chat = ''
     self.charType = ''
     self.clerk = 0
开发者ID:coginvasion,项目名称:src,代码行数:11,代码来源:DistributedChar.py

示例2: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
    def __init__(self, cr):
        DistributedSmoothNode.__init__(self, cr)

        self.actor = None
        self.isMoving = False
        self.name = ''
        self.chat = ''
        self.nameText = None
        self.nameTextNP = None
        self.chatText = None
        self.chatTextNP = None
开发者ID:ToontownLittleCat,项目名称:dist-ralph,代码行数:13,代码来源:Ralph.py

示例3: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
    def __init__(self, cr, playerId = None):
        DistributedSmoothNode.__init__(self,cr)
        # you have to initialize NodePath.__init__() here because it is
        # not called in DistributedSmoothNode.__init__()
        NodePath.__init__(self, 'avatar')

        self.playerId = playerId

        self.setTag('paintType', 'avatar')

        # This point is in the middle of the avatar, for determining
        # paint normals and such.
        self.center = self.attachNewNode('center')
        self.center.setZ(0.5)

        self.lastPaintPoint = None
        self.paintDirty = False
        self.flushTask = None
        self.p = None
        self.tex = None

        # A dictionary of player -> count, showing the number of
        # pixels that each player has painted onto this avatar.
        self.players = {}

        self.actor = None
        self.nametag = None
        self.moving = False

        # This is true if this avatar represents the "local avatar",
        # the player at the keyboard, as opposed to a remote player.
        self.localAvatar = False

        # Create an "into" collision sphere so it becomes tangible.
        cs = CollisionSphere(0, 0, 0.5, 0.5)
        cnode = CollisionNode('cnode')
        cnode.addSolid(cs)
        self.cnp = self.attachNewNode(cnode)
        self.cnp.setCollideMask(Globals.AvatarBit)
开发者ID:ToontownLittleCat,项目名称:tagger,代码行数:41,代码来源:TagAvatar.py

示例4: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
    def __init__(self, cr):
        try:
            self.DistributedToon_initialized
            return
        except:
            self.DistributedToon_initialized = 1

        Toon.Toon.__init__(self, cr)
        DistributedAvatar.__init__(self, cr)
        DistributedSmoothNode.__init__(self, cr)
        self.questManager = QuestManager.QuestManager()
        self.token = -1
        self.ghost = 0
        self.puInventory = []
        self.equippedPU = -1
        self.backpackId = None
        self.backpack = None
        self.animState2animId = {}
        self.battleMeter = None
        for index in range(len(self.animFSM.getStates())):
            self.animState2animId[self.animFSM.getStates()[index].getName()] = index

        self.animId2animState = {v:k for k, v in self.animState2animId.items()}
        self.initAmmo = []
        self.initGagIds = []
        self.headMeter = None
        self.firstTimeChangingHP = True
        self.gagBPData = []
        self.quests = []
        self.tier = None
        self.questHistory = None
        self.busy = 1
        self.friends = None
        self.tutDone = 0
        self.hoodsDiscovered = []
        self.teleportAccess = []
        self.lastHood = 0
        return
开发者ID:coginvasion,项目名称:src,代码行数:40,代码来源:DistributedToon.py

示例5: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
 def __init__(self, cr):
     ShadowCaster.__init__(self)
     DistributedSmoothNode.__init__(self, cr)
     NodePath.__init__(self, 'Projectile')
开发者ID:MasterLoopyBM,项目名称:c0d3,代码行数:6,代码来源:DistributedProjectile.py

示例6: __init__

# 需要导入模块: from direct.distributed.DistributedSmoothNode import DistributedSmoothNode [as 别名]
# 或者: from direct.distributed.DistributedSmoothNode.DistributedSmoothNode import __init__ [as 别名]
 def __init__(self, cr):
     DistributedSmoothNode.__init__(self, cr)
     NodePath.__init__(self, "Model")
     self.model = base.loader.loadModel('smiley.egg')
     self.model.reparentTo(self)
开发者ID:grimfang,项目名称:owp_dungeon_crawler,代码行数:7,代码来源:DistributedPlayer.py


注:本文中的direct.distributed.DistributedSmoothNode.DistributedSmoothNode.__init__方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。