Hi, I have coded something but am not able to move the character. Please have a look at it and give some feedback. Thanks in advance.
Create your own game!
GAME_DURATION = 60
Spawn a player with spawnPlayerXY()
player = game.spawnXY(“knight”, 36, 30)
game.spawnXY(“gold-coin”, 51, 58)
player.maxSpeed = 50
player.maxHealth = 1000
player.maxAttackDamage = 100
Add at least one goal!
game.addDefeatGoal()
if game.defeated == 5:
game.setGoalState(DefeatGoal, True)
Spawn objects into the game with spawnXY()
game.spawnMaze(“forest”, 9)
game.spawnXY(“generator”, 60, 12)
“generator”.spawntype == “scout”
Welcome to the forum! This is a family-friendly place where coders can share bugs, ask for help on any CodeCombat level (don’t forget to post your code correctly ), or just hang out with other coders. But before you proceed, please check out our guidelines: this topic.
Have a great time!
Can you please format your code correctly by clicking the gear button and the </> button. Those who can help you will be able to read your code easier. Thanks!!
2 Likes
Are you still here? @VasishtG7 ?
Create your own game!
GAME_DURATION = 60
Spawn a player with spawnPlayerXY()
player = game.spawnPlayerXY(“knight”, 36, 30)
game.spawnXY(“gold-coin”, 51, 58)
player.maxSpeed = 50
player.maxHealth = 1000
player.maxAttackDamage = 100
Add at least one goal!
game.addDefeatGoal()
if game.defeated == 5:
game.setGoalState(DefeatGoal, True)
Spawn objects into the game with spawnXY()
game.spawnMaze(“forest”, 9)
game.spawnXY(“generator”, 60, 12)
“generator”.spawntype == “scout”
Try this code
Hi, I have solved the code, I will try to improve it using this code
Thx
Could I see your game? I would love to try it! If so put it here! I (hopefully) can’t wait to try it!
Post your best game development project here! I will review them all and announce the best one!
Ok but it is not that good so is it okay if I try to use some of the techniques that u mentioned before showing it to you?
Sure!!!(20 charsssssssssssssss)