Home  >  Article  >  Java  >  Pokemon Battle Simulator/Showdown Clone Devlog#0

Pokemon Battle Simulator/Showdown Clone Devlog#0

王林
王林Original
2024-07-22 16:36:33543browse

Pokemon Battle Simulator/Showdown Clone Devlog#0

Intro

This is a random devlog that I use to keep track of random things, and also as a time capsule for idk
The project is, as the title suggests, is a Pokemon Battle Simulator written in Java. It will be an offline one, only using AI as the second player. Multiplayer functionality is not intended to be made.

Prologue

Dang, why did I just think of making a devlog now? Should’ve done it since the beginning or whatever.
If you’re reading this, welcome! Feel free to leave any feedback. Criticism is really needed. Heck, any comment is appreciated, as long as it’s specific so I know which part of it is good/bad.

Progress so far:

  • Made basic stat calculations from name, IVs, EVs and nature.
  • Basic move calculations with only damage, with type effectiveness, STAB, crit and random[0.85, 1.00]
  • That’s it ig?

Project Structure (at the time of writing this):

public class Pokemon
    // calls pokemon.csv for initialization
    : all stats (hp, attack, defense, specialAttack, specialDefense, speed)
class BattlePokemon extends Pokemon
    : effective stats for each stat
    : accuracy and evasion
    : stat changes (array)
    // only initialized in battle
public class Move
    // calls moves.csv for initialization
    : power, accuracy, PP
    f() apply
        f() calculate damage
        f() handle effects
class TypeChart
    // is used by f() calculate type multiplier
    // calls typechart.csv for type chart
public class Battle
    // does nothing rn
    f() turn // does nothing as well

The above is the detailed content of Pokemon Battle Simulator/Showdown Clone Devlog#0. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn