Skip to content
← Back to Community
Pokemon Battle (C++ version)
Profile icon
nN34398Ff

POKEMON BATTLE C++ VERSION!

A long time ago, I tried making
a pokemon battle on python.
I sucked so badly that it took literally
500 lines and nothing worked. Then...

AFK TIME!

After a while of
scratch.mit.edu and boredom...

C++ COMES UP AND TAKES OVER!
Now I know a bit of C++ (enough to make this, at least). I used it to remake the python project from long ago... and it WORKED! Now you can actually fight, and it's only around 100 lines!


I will soon add:

  • more moves DONE! ✅
  • more items Not yet =( ❌
  • maybe more POKEMON? Not yet =( ❌

That button at the top left which has a number in it looks so sad and gray... how about you click it and make it green and happy?? =D

To type "scratch" and
spam "potion" or not to...

Hey there's new moves for the enemy check them out =D

Cool kid club:

image

Oh the jellybeans
how delicious they are
yay
especially the pink lemonade ones
mmmm

Voters
Profile icon
KNMS-6H-DEVSHYA
Profile icon
TDAntZ
Profile icon
JackSorgenfrei
Profile icon
IliaMielnik
Profile icon
NathanMarchant
Profile icon
AARONALCIVAR
Profile icon
BraedenBlanchar
Profile icon
Alexander-Dariu
Profile icon
billydunnet
Profile icon
RiddleMeThis23
Comments
hotnewtop
Profile icon
DynamicSquid

Cool! Few things though:

#include <cstdlib> // what is this, #include <stdlib.h> // and this for? using namespace std; // you don't need this
Profile icon
nN34398Ff

Thanks!!!!!! I took out the unneeded #stuff
@DynamicSquid

It was for a color text thing and a clear the terminal thing... Do you know how to clear the terminal using code?

Profile icon
DynamicSquid

@nN34398Ff system("clear")

Profile icon
nN34398Ff

@DynamicSquid
Screenshot 2020-07-30 at 4.28.32 PM

Profile icon
nN34398Ff
Profile icon
DynamicSquid

@nN34398Ff try to put it in your c++ code, instead of typing it out in the shell

Profile icon
nN34398Ff

@DynamicSquid Ok thanks

Profile icon
DynamicSquid

@nN34398Ff yup, np!

Please mark this as accepted if it helped you

Profile icon
nN34398Ff

@DynamicSquid Accepted!

Profile icon
nN34398Ff

So I just say accepted? Ok @DynamicSquid

Profile icon
DynamicSquid

@nN34398Ff you have to click on the checkmark

Profile icon
nN34398Ff

@DynamicSquid Oof I'm a noob... i'm not sure what u mean...

Profile icon
frissyn

@DynamicSquid lmao this isn't an ask post

Profile icon
DynamicSquid

@IreTheKID OOOOOOOOOOOOOOHHHHHHHHHHHHHHHHHHHHH yeah I knew that lol

Profile icon
nN34398Ff

@DynamicSquid Ok I knew it had to be an ask post!! (totally XD)

Profile icon
EpicGamer007

@IreTheKID, what algorithm did you use to calculate if the person is a spammer in your rc website becuase it says I am 99%-100% a spammer and I want to get it lower... It is really embarrassing. I didn't think I was a spammer...

Profile icon
[deleted]

@DynamicSquid I always use

using namespace std;

It always saves me some time from typing std::
But thats just how I do it.

Profile icon
nN34398Ff

@CarlosRosiles Yeah I can do that but I really don't care, it's pretty fun to type so yeah. DynamicSquid is talking about way earlier, when I randomly had it there.

Profile icon
nN34398Ff

@IreTheKID woah you made the rc website!!! amazing!! Also how am I a spammer???? XD

Profile icon
frissyn

@nN34398Ff & @AbhayBhat

Find more info about the Spam Score here.

Profile icon
EpicGamer007

@IreTheKID, uh, the link never loads

Profile icon
frissyn

@AbhayBhat should be good now, found a few bugs in the code :/

Profile icon
nN34398Ff

@IreTheKID it still doesnt work =(

Profile icon
frissyn

@nN34398Ff it should work, what's wrong?

Profile icon
nN34398Ff

@IreTheKID I go to the link you posted (your website) then I press on the blue link within the website... then it crashes.

Profile icon
nN34398Ff

@IreTheKID
First this:
image
then this:

Screenshot 2020-08-03 at 7.44.13 PM

image

Profile icon
frissyn

@nN34398Ff you need to open the site in a new tab lol

Profile icon
ZAHASA293002

Healing doesn't work fully. When im supposed to read 250 i get sent down to 100. Also, their attacks can do like 150 dmg

Profile icon
xxpertHacker

Didn't expect someone to ever say they preferred C++ over Python, and nice job!

Keep it up, I for one can't wait to see what happens when you know even more!

Profile icon
nN34398Ff

@StudentFires Thank you! Yeah, it's a bit weird, considering python is 10 times easier than c++ but I guess I kinda understand c++ better... =D Maybe after learning c++ I can go back to python and fix up my python version of this.

Profile icon
nN34398Ff

mmm jellybeans

Profile icon
Leroy01010

can you make it say the moves again

Profile icon
nN34398Ff
Profile icon
nN34398Ff
Profile icon
nahu1

AWESOME

Profile icon
nN34398Ff

@nahu Thanks!

Profile icon
nN34398Ff

image
Top ten least used programming languages compared to python! I got this from https://rc.irethekid.repl.co/statistics

Profile icon
HahaYes

@nN34398Ff well because python is used by kiddos a lot.

Profile icon
nN34398Ff

@HahaYes yes and a major part of the replit population is kiddos =)

Profile icon
HahaYes

@nN34398Ff everyone knows python is slow and C++ and C are fast

Profile icon
nN34398Ff

@HahaYes HAHA YES!

Profile icon
nN34398Ff

@HahaYes everyone except my bro XD

Profile icon
nN34398Ff

@HahaYes But it is pretty good... I use it rarely tho, cause to me c++ is easier to remember. Eh. I have no idea why. =D

Profile icon
HahaYes

@nN34398Ff hahayesssssss

Profile icon
nN34398Ff

Wow so many famous coders are upvoting this!!! Thanks all you guys!

Profile icon
gibbsfreenergy

It doesn't work dude.

Profile icon
nN34398Ff
Profile icon
nN34398Ff

@JosephSanthosh maybe u went on while I was editing. Check now...

Profile icon
gibbsfreenergy
Profile icon
LTI2

game is kind of easy

Profile icon
nN34398Ff

@LTI2 Yup, the enemy really does suck. But don't worry, I'm going to add more.

Profile icon
nN34398Ff

Ok now it's a bit harder @LTI2

Profile icon
nN34398Ff

Holy cow I made this today and suddenly it's second on the most popular "share" trending thing =0 Thanks to highwayman and dynamicsquid!!! Man the're awsom

Profile icon
Highwayman

scratch scratch scratch potion potion scratch potion flame flame potion potion potion potion flame flame flame scratch potion potion flame...

Profile icon
nN34398Ff

@Highwayman yeeeeeeeeeeeee lets go infinate potions XD

Profile icon
Highwayman

YEA! 😜@nN34398Ff