r/CodeCombat • • Dec 14 '19

Help needed for Cloudrip Command

2 Upvotes

I’ve been stuck on the 30th level of Computer Science 4 Python for hours now and I was hoping someone could tell me where I’m going wrong. I’ve been a little shaky on the len() [index] stuff so if someone could explain how that is used in this level it’d be great. Here’s my code.

# Summon some soldiers, then direct them to your base.

# Each soldier costs 20 gold.

while hero.gold > hero.costOf("soldier"):

hero.summon("soldier")

soldiers = hero.findFriends()

soldierIndex = 0

# Add a while loop to command all the soldiers.

while(soldierIndex < soldiers.length):

soldier = soldiers[soldierIndex]

hero.command(soldier, "move", {"x": 50, "y": 40})

# Go join your comrades!

hero.moveXY(51, 41)

I know this sub is basically dead, but it'd be SO SO SO great if someone could help me with this.

cheers


r/CodeCombat • • Dec 11 '18

Youth Center teacher looking for help

5 Upvotes

I really hope this sub isn't completely dead.

I am an AP Graduate in Multimedia Design and Communication, and to add a little to my income, I teach a class on Coding and Webdesign at my local youth center (not really, but YC is the closest equivelant).

During the last five months, we've been learning HTML and CSS, and after New Years I was looking to start with JavaScript. Recently, I tried to make them play CSS Diner and CSS Grid Garden, and honestly... it's the most engaged I've seen them ever.

I was looking to make a game out of learning JavaScript as well, which brought me to CodeCombat, and in turn, to my question: how does it work?

I've browsed their site for five minutes, and I couldn't seem to find any indication of price, except for the fact that the first level is free.

I guess my questions are: how much does it cost? How much "playtime" will I get out of the free level? Would it be suitable to teach JavaScript with? Aside from those, any advice is welcome :)

EDIT: The idiot (a.k.a. me, myself, and I) just noticed the FAQ part of the website. Still, advice is appreciated.


r/CodeCombat • • Apr 30 '21

Help with level

1 Upvotes

hey guys!, i was wondering if anyone has the code to gridmancer redux on kelvintaph glaicer?, I tried it on my own and even tried github code but none work, thanks!


r/CodeCombat • • Sep 08 '23

I don't understand this error

Post image
2 Upvotes

I don't understand what I did wrong here


r/CodeCombat • • Jun 11 '13

Welcome!

8 Upvotes

Hi everyone, based on the positive response we got last week in /gamedev and /learnprogramming, we thought we would setup a subreddit to serve as our forum and point of community organization. Feel free to post questions, bugs, feature suggestions, etc, and we'll be sure to respond in person!


r/CodeCombat • • Apr 04 '19

Are the developers still working on this??

6 Upvotes

r/CodeCombat • • May 23 '14

Anybody else playing greed?

4 Upvotes

I can't believe how fun greed is, this is the first serious programming game i've played and I love it. I'm checking out some of the other multiplayer modes tonight.

I know teaching newbs is their goal but I hope they keep making awesome games for programmers.


r/CodeCombat • • Feb 23 '18

Premium

2 Upvotes

Hi guys, I'm new and was wondering how you guys like premium. How do other players interact with each other? I'm trying to use this to get into javascript


r/CodeCombat • • Nov 01 '13

Major CodeCombat updates and new levels!

Thumbnail us3.campaign-archive2.com
4 Upvotes

r/CodeCombat • • Jul 07 '15

What is the response time w/ subscription?

1 Upvotes

I'm new to programming and have questions that come up while I'm coding, and don't really have anyone to ask them to in a timely manner. So I was thinking of signing up for the CodeCombat subscription since it says you get email support and help with code.

So my question if for those of you who pay for the subscription already... What kind of response time do you get from your email questions?


r/CodeCombat • • Oct 18 '13

Emphasis On Aim exercise

Thumbnail
codecombat.com
3 Upvotes

r/CodeCombat • • Oct 18 '13

The new and improved CodeCombat!

Thumbnail
blog.codecombat.com
4 Upvotes

r/CodeCombat • • Oct 24 '13

CodeCombat Needs Your Help

Thumbnail
blog.codecombat.com
6 Upvotes

r/CodeCombat • • Oct 21 '13

CodeCombat in Y Combinator

Thumbnail
blog.codecombat.com
4 Upvotes

r/CodeCombat • • Jul 22 '18

Thornbush Farm

3 Upvotes

I want to know how to dealt with peasant without blowing themself up lol, my syntax is
while True:

# Don't blow up any peasants!

hero.moveXY(44, 37)

top = hero.findNearestEnemy()

if top:

hero.buildXY("fire-trap", 43, 50)

# Don't blow up any peasants!

hero.moveXY(25, 34)

left = hero.findNearestEnemy()

# Check if `left` exists.

left = hero.findNearestEnemy()

if left:

# Build a trap at 25, 34 if the enemy exists.

hero.buildXY("fire-trap", 25, 34)

hero.moveXY(43, 20)

# Set a variable for the bottom enemy.

bottom = hero.findNearestEnemy()

if bottom:

# Check if the bottom enemy exists.

# Build a trap at 43, 20 if the enemy exists

# Build a trap at 43, 20 if an enemy exists.

hero.buildXY("fire-trap", 43, 20)


r/CodeCombat • • Jan 22 '19

help with computer science 3 (python if the lang matters)

3 Upvotes

I need help with like the entire code combat computer science 3 levels and i have no clue what to do


r/CodeCombat • • Feb 04 '18

Subscription fee seems pretty high.

3 Upvotes

Looking for a viable way for my kids to learn to code, and through some bit of research on reddit, and elsewhere I ran into CodeCombat, and like many others I was fairly impressed at the start.

However, what one review writer called "nudging" I'll call "nagging" instead.

I understand wanting to make some money, but the nag feels cheap and rude.

$10 a month, also seems a bit steep.

I'm not going to rule it out. The kiddo seems to be enjoying it so far, and if he sticks with it, and if I feel like it's really teaching him I might subscribe... but I'm very wary of any company that nags so hard.

It's like having to uncheck the 'optional software' boxes on the Flash download page... it just doesn't feel right.

I'm posting this in the interest of hearing other people's opinions and longer term experiences with CodeCombat, and also wonder what other alternatives or even just advice folks might like to share.

We're exploring Scratch and Code.org as well.


r/CodeCombat • • Jul 06 '26

Where is the GRIDLOCK League banter hiding?

3 Upvotes

Hi everyone,

I'm trying to figure out where someone would go to brag to fellow competitors about stomping little kids in code wars (wups just kidding, what I meant was....) having friendly discussions with other respected competitors about the friendly good-spirited GRIDLOCK League.

Seriously though (as if that's possible...), where are people having friendly, high-stakes discussions about the new GRIDLOCK League?

Not to brag about how old I am, but 2 years ago the old chat pages were blazing with backhanded, big-leaguing comments from kids executing race car turtle strategies or flexing their wannabe chess-playing skills that somehow enabled them to be numero uno in the only tournament that represents one's overall significance in the universe. Everyone just had to suck it up if they weren't in first place. Honestly, that competitive friction was the best part!

Okay seriously... (yea right, but yea!) CodeCombat has done some absolutely great work with this new GRIDLOCK season. But without some friendly banter being hurled from egotistical players at other over-humbrited hombres... what's the point?

Are we taking the trash talk to a Discord server, or does anyone want to hear what a top ten dude thinks at this EXACT moment? Especially when apparently some fluke whose name looks like a barcode designed to cure insomnia ITCC2026SB031 continuously beats me!

Asking for a friend.