AI Bot Challenge

← Back to all posts
97
Dragon Eye RPG

This is an RPG made for the AI competition. The game is intelligent by generating a story and determining enemy moves.

About

Dragon Eye is a terminal based RPG. It may not be a AAA game, but it does have one special thing about it. Since there is no story, the game is generated by an AI based on decisions you have made.

Enemies

You can fight a variety of enemy's in the game. Before combat the game generates your enemy to be close to your level and damage, that way every fight is fair, and a decent challenge.

class Enemy{
  public int Level;
  public int Health;
  public string Race;
  public int Damage;
  public int Defense;
}

Items

Items are essential to playing Dragon Eye, without them you would most likely be on a death loop.

class Item{
  public string ItemType;
  public string ItemName;
  public int ItemLevel;
  public int Damage;
  public int Value;
}

Strategy

The gameplay is based on strategically making decisions. You always have 3 options in combat, attack, defend, and use item. Using an item will heal you with an item, defend will use your defense to counter the enemies next attack, and attacking will use your attack and subtract that from the enemies health.

class Player{
  public string Name;
  public int Level;
  public int Health;
  public string Race;
  public int Damage;
  public int GP;
  public int Defense;
  public int xp;
  public List<Item> Inventory = new List<Item>();
}
Commentshotnewtop
3

completed it mate

2

GP -21

1

@LOLLOL3 dang u broke, pay me your debt in gold

3

its very
good but needs a toootorial

2

Level -1 enemy

1

@ebest yeh u better not lose to him

1

@PixelBitez Won. It did not give me health though...

2

WOW! AMAZING! I made a hacked version with the stick called "DB" it has 1000 Damage.
Here is the link to it if you wanna play it: https://repl.it/@ChristianThone/Dragon-Eye-RPG-HACKED

1
2

Why people always tryna hustle me for my money?

2

Hey can you make it that when you choose an item, that you dont have to type in capital letters for ex. you just type in “stick” instead of “Stick” it would make it easier for people I would think.

2

It has some lack of info, but overall it is a very good attempt. Noice!

2

at the first battle how do i attack?

2

@skull_is_dull You have to type the number of the action, so in order to attack you type "1". Then it will ask what to attack with, type in "Stick" as it is the starting item in your inventory.

1

@PixelBitez Although there is the problem if you type Attack instead of 1 your turn is skipped. Also, typing stick instead of Stick is also invalid.

2

@EatTofuEveryDay @PixelBitez You can easily fix this by using the .lower() function on your inputted variable, and the code will no longer be cap sensitive.

if input("Attack with what? ").lower() in inventory:
1

@KiKUP yeh ik but then i'd have to add a lot more code because the way I made combat is complicated

1

@PixelBitez Sure thing! I'm anxious to see what more you can do with this! :)

1

Very cool!

Unrelated question: How do you generate random numbers?

1

@KasCode_Inc u gotta type:

Random rnd = new Random();
int randomNumber = rnd.Next(min, max);

max being the maximum number and min being the minimum

1

When monsters are low on health they can regenerate some health back every turn?

1

@mkhoi yeh they do sometimes

1

ayyy we did it homies, i might make a complete story driven version of this

1

FYI - someone has taken this game and posted it saying it is theirs https://repl.it/talk/challenge/Loa-RPG-WIP/10637
i ma absolutley DISGUSTED

2

@LukeGordon2 dang that person needs to be creative instead of stealing work

1

Vote for Ultimate AI it is the best

1

@AmarMalhi your a little late my guy the comp ended yesterday

1

When the game say's "Someone walks up to , and asks him/her to slay a monster." Mine auto says "declined the offer" but then automatticaly says "Someone walks up to _, and asks him/her to slay a monster" then "___accepted the offer" fix that part maybe

1

I cant beleive an easy AI like this is beating a machine learning AI that plays chess.... ppl these days

1

your game is broken

1

Was being healed when defending made on purpose?

2

@RyanTjia Yeah, its because some fights can get really hard.

1

Okay so I read your coding and I saw that you can purchase other weapons. Why isn’t it doing that in the actual game?

1

@Sparkster I'm not sure, I think it may have to do with the random numbers, and that the switch function only goes up to 3, not 5. If not then I am not sure.

I fixed it.

1

And what is this “ somtin special” thing i put it in but it said incorrect input . @PixelBitez

1

@Sparkster Just ignore it, it was used for testing purposes.

2

@Sparkster you have to type "somtin special ;)". You just forgot the smiley.