@stetim94 wrote a ridiculously awesome game of Pokemon, and it’s great. I just wanted to make this topic to talk about it, (he’s not on atm but probably will be tomorrow.) I figured that other people might want to test it or talk about it, but I just have stopped personal messaging for now and still wanted to bring attention to the fact that this is the awesomest.
but the code base still needs fine tuning, i should have used oop which is better practice for tkinter
I actually liked it a lot. You’ll be changing it for a while, but I think it’s great that you got the idea and made it happen.
But I generally prefer OOP, just because it seems very complete to me.
i am currently trying to rewrite it to use classes (oop), now i have the code base, this should be fine
That sounds really good! I’m still going through the other one.
did you ran it and play it? i haven’t many any comments to the code, bad practice
I haven’t run it yet! I will later. I’m bad about adding comments to mine as well, I only really do it for knowing what brackets I’m closing in Java or JS.
how can you know how awesome it is, if you haven’t ran it?
I followed this thread expecting the source to be linked to
So far I’m very disappointed
kyleaw.txt (19.0 KB)
so far, this code requires python3 and tkinter. I am personally not happy with the code base, currently re-writing it.
Would it be cleaner with game logic and graphics being separate from each other?
if i was capable of doing so, yes, but so far, i am happy that it works
Do I get to comment on it?
I would:
- Move the pokemon data and class into its own file.
- Create a class for their moves
- Create a method in the pokemon class that takes a move as input and removes a suitable amount of damage, updating its life/status (leave me alone I never played pokemon)
- Move gui to its own file, providing functionality that accepts pokemons and draws the different views based on that
- What’s remaining would hopefully then be some kind of high-level overview that delegates the details of combat to the pokemon file and the drawing to the gui file. Reading this file would be a quick way to understand how the game plays out
some cool suggestions, i will see what i can do, but it is just for sinterklaas ( a dutch holiday), but some good coding practice would be good for my skill.
make sense, i will implement it.
can you give a small example of how this should be?
this sounds like a brilliant idea, i will most certainly implement this. i think once i implemented the OOP version of this game, this will be a lot easier.
Lets hope so, i will post updated when i have them.
Thank you for taking the time to help me with this
I think these are really nice suggestions as well. Specifically the first one seemed really smart, because I didn’t even realize this was possible until yesterday, (which is crazy.)
The rest of them were really good as well. It really makes the program more professional. [quote=“ionatan, post:13, topic:67146”]
(leave me alone I never played pokemon)
[/quote]
How now?!
That sounds a whole lot like “Santa Claus”
I’m excited to see what you do with it.
I was looking to make them a little more formal and recognised as significant things in the program, seems more suitable to write move.type than move[‘type’], the former says things like “this type of value has a couple of attributes that all do different things and those things are significant to the logic of the program”
So it’s a style preference. You could totally keep the dicts.
okay, then i will think about it. I will implant the other changes, but first i want OOP, i learned now how to do this in TK. Should be able to finish that today or tomorrow, then i will start on your suggested changes
i am currently rewriting it it with OOP, there is a text file available with functional programming.