The “Bad guys politely waiting their turn to attack” Award


Presented by Cosmologicon to:

Bone Rush (ThEdA_P26)
Important Fix (Windows)

Thank you @gummbum for pointing this out to me in the discussions. 

main.py: 

  • 61: cr.LoadScene("Scene/main.ccreator")
  • 66:  pyglet.resource.path.append("Resources/creator")

gameplay.py:

  • 83: self.attack_sounds.append(pyglet.media.load("Resources/creator/Audio/" + sf, streaming=False))
  • 84: self.hurt_sound = pyglet.media.load("Resources/creator/Audio/attack.wav", streaming=False)
  • 87: self.skeleton_walk_imgs = list(map(lambda x: pyglet.resource.image("Texture/skeleton/"+ x), images))
  • 90: self.skeleton_attk_imgs = list(map(lambda x: pyglet.resource.image("Texture/skeleton/"+ x), images))
  • 92: self.skeleton_fall_img = pyglet.resource.image("Texture/skeleton/fall.png")
  • 208: spr = cocos.sprite.Sprite("Texture/skeleton/walk1.png")

ccbreader.py:

  • 199:  font_name=lbl.FontName().decode('utf-8')[:20],


Details about the fixes quoted above:

The game is failing to run on windows due to some issues in pyglet library

Error1: Replace all os.path.join() calls the actual path (fails with assert when using os.path.join for relative paths) 

Error2: pyglet label fails with error saying unable to proceed:

Thank you for taking time to try out my game. Sorry for the trouble, lesson learnt, test on windows before uploading final version :)


This is a simple arcade game with simple two button input. You have to tap left-arrow when there is an enemy to the character's left and tap right-arrow when there is an enemy to the right

InGame Screenshot

If you are a fan of cocos library you should definitely try to look at the way i've used the "Cocos Creator" editor for setting up the scene to render in-game. I've leveraged the same workflow i used in my previous pyweek entry.  

Libraries:

  • Cpp-Lua plugin for Cocos Creator [https://github.com/cocos2d/creator_to_cocos2dx]
  • FlatBuffers for python
  • cocos (python version) [https://github.com/los-cocos/cocos]
  • pyglet

Tools Used:

  • Cocos Creator 1.9
  • Dragon Bones Pro [Animation]

I'm not sure how popular cocos still is but i've been used to cocos because of cocos2d-x and cocos-creator so tried to leverage that experience by using the same on python side. I would love to see cocos-creator editor support get added to cocos library project but thats a discussion i should still start and see.