PDA

View Full Version : PokeClone: A Pokémon engine coded in Python


m.vit
July 12th, 2012, 11:01 AM
[css-div="padding-left:10px; border: 1px solid #000; color: #FFF; text-shadow: 0px 1px 3px #000; background-image: url('https://dl.dropbox.com/u/5191095/gradient.png'); background-repeat: repeat; background-color:#6CBF61; height:40px; line-height: 40px;"]PokeClone: A Pokémon engine coded in Python
[/css-div]
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Introduction
[/css-div]
PokeClone is developed by tpw_rules, sonicrules1234 and m.vit, it's intended to be an engine base (like Pokemon Essentials) however coded in Python, allowing for more expandability and variety, the current version is v 0.1 and supports many overworld features. We're using this engine to create Pokemon Bronze, which is currently looking for team members.
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Features
[/css-div]
As of v 0.15 PokeClone supports:

Basic overworld movement
Warps
Cutscenes
Trainer spotting
NPC dialog
Self dialog
Choice dialog
Basic surf support
Animated tiles
Attack System (not battle system)
Black/White-like animation
Saving

[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Media
[/css-div]
9pD-ZNcBixo
http://f.cl.ly/items/0p2P420O2g3O350v3X28/Screen%20Shot%202012-03-11%20at%2010.29.47%20PM.png
http://f.cl.ly/items/2L0U251f3a3c2A0K0k0s/Screen%20Shot%202012-03-17%20at%204.48.43%20PM.png
http://f.cl.ly/items/0W2Z0O260G1c3X2z1g1f/Screen%20Shot%202012-03-17%20at%2011.57.07%20AM.png
(More updated screenshots coming soon, feel free to submit your own and I'll gladly add them here)
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Dependencies
[/css-div]
To be able to use Pokeclone you need:

Python 2.6+
Pygame
PyOpenGL

[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
FAQ
[/css-div]
I want to create my own map, where should I start?
If you want to make maps, open up Tiled, select your sizes and go! Make sure you have a "Collisions" layer and use the collisions tileset provided to use them.
What about NPCs/Trainers/Cutscenes?
In the data/maps folder in the source you can find some xmls that share the map's name, for now use those as reference.
I found a bug! What do I do?
In your .exe folder or source folder you'll find a file called exception.txt, paste the contents in Pastebin or a similar service and post the link here.
Where can I find more info about doing (insert here)?
PokeClone's source includes some basic documentation, and in the source link you will be able to find a wiki which will be edited to fit your knowledge needs
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Downloads
[/css-div]

v 0.1 Executable (Outdated, please compile your own!) (https://dl.dropbox.com/u/4355351/pokeclone.zip)
Source Code and Wiki (https://github.com/tpwrules/pokeclone)
Tiled Home Page (http://www.mapeditor.org/)

[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Developer Channel
[/css-div]
If you want to look for some help, discuss about code or new features, feel free to join us on IRC, we're on #pokeclone in Freenode.
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Help Wanted!
[/css-div]
We're looking for Rom Hackers who can help us translate ROM data into XML files (like Pokémon B/W Animations) and developers who know OpenGL!
[css-div="background-color: #cacad2; color:#000;text-shadow: 0px 1px #FFF; width: 100%; border-bottom: 1px solid #000;"]
Credits
[/css-div]
Nintendo and GameFreak for Pokemon
Pokemon-Diamond, Thunderdove and Serebii08 for their amazing tiles
Sonicrules1234 for ROM to XML conversions

khkramer
July 12th, 2012, 11:20 AM
Nice!
I'm going to give this a try right away

Edit: I lol'd at the jesus boots xD

Spira
July 12th, 2012, 09:34 PM
Well done. Almost makes me want to continue working on the Python Pokemon game I was helping to create! Hope to see more in the future from you!

m.vit
July 14th, 2012, 10:42 PM
Remember you guys can fork the source and implement your own maps and features!

Dragonite Ernston
July 15th, 2012, 10:33 AM
I'd fork and help if I knew the slightest thing about what you guys were doing. I've never used PyGame before, and it took me a while to figure out that pokeclone.py was the startup file. D:

godo156
July 17th, 2012, 09:40 PM
Seems interestin'. Well good luck on this ya two. I might make a game from this eventually, if ya don't mind.

KingCharizard
July 18th, 2012, 03:31 AM
This is interesting but I'd love to see some screens or maybe a video... if you have as much done as you say media shouldn't be a problem.....

m.vit
July 18th, 2012, 11:05 AM
I'll add some screenshots of earlier builds since I'm not near my desktop at the moment, would be nice to have user submitted screenshots with custom content

godo156
July 31st, 2012, 11:08 AM
Don't know if this counts,
http://i1213.photobucket.com/albums/cc463/Godo-kun/Spritetest.png
but here's proof that the player sprite can and has been edited.
Can't edit the game itself because I have no idea how to install python or pygame on my windows 7 computer...

DOA_Hitomi
August 4th, 2012, 08:59 AM
This should work on windows then?

Don't know if this counts,
http://i1213.photobucket.com/albums/cc463/Godo-kun/Spritetest.png
but here's proof that the player sprite can and has been edited.
Can't edit the game itself because I have no idea how to install python or pygame on my windows 7 computer...
You can get python on windows here:
Get Python 2.7.3 for Windows (http://www.python.org/ftp/python/2.7.3/python-2.7.3.msi)

Whitney's Shaymin
August 4th, 2012, 11:57 AM
This cool but when can we make our own game out of it?

godo156
August 8th, 2012, 10:03 AM
This cool but when can we make our own game out of it?

When they get to a point where it's possible. Just work with what you can at the moment really. Oh, and thank you person with the python link. I'll download it when I get to a computer.

nuzamaki90
August 12th, 2012, 01:26 AM
Jesus Boots XD

I played with the engine a bit and it's actually really nice, just needs a few more things added to it.

Excited for the next release.

m.vit
September 11th, 2012, 06:37 PM
Quick update to keep this thread from being dead!

We've started OpenGL implementation! (woo!) what does this mean?

Firstly, a new dependency, PyOpenGL.

For now it's implemented in the animation system (yet it's only in the tool, not in the very early battle screen), it brings higher frames per seconds, amazing fluidity in animations (I truly mean it!) and hopefully will make our lives easier with adding bigger content (bigger maps, battle tweens, battle animations) without consequences (frame drops mostly)!

Go ahead and try out the animation tool! It's very easy to load an animation, in your terminal type out the following
python tools/animation_view.py pathtoanimation(must be in data folder) animationname(demo/battle, just check the xmls)

I'll be starting a PokeClone resource git...sometime... so that others can contribute with battle graphics, animations (we need all 649 pokémon!), new features, etc...

Also feel free to discuss features and their implementations here, I was thinking of a universal GTS, just send new fakemon data to a database and watch it sync across all pokeclone games? who knows! virtually anything is possible with python in comparison to other platforms!

DaSpirit
September 12th, 2012, 04:41 AM
OpenGL sounds awesome! Which minimum version are you supporting?

m.vit
September 13th, 2012, 05:49 PM
PyOpenGL supports from 1.1

pokeMa7as
September 15th, 2012, 10:31 AM
Cool, I like Python. Good luck!

m.vit
September 19th, 2012, 07:23 PM
I'm officially announcing the first PokeClone-powered game!
http://f.cl.ly/items/2n3d0C1Q2e1F3w2i1N2u/BRONZE-VERSION.png
So what is it? Well well well, think about it as a Pokémon Prism 2, a new adventure in the region of Naljo!

I already asked Koolboyman and he said yes, hence why I'm making this announcement.

So, to show the power of PokeClone it will expand upon Prism's features, right now I have a working Pokemon-controlling area and a 2D sidescrolling area, which will be further expanded than Prism's appearance, it will feature new/reworked areas, new dialogs/characters/gym leaders, and hopefully 3D!

Here's a quick teaser, yet i'm sure you saw the titlescreen already in the current PokeClone build ;)

http://f.cl.ly/items/2p3x0O2H343T0s2J271H/Screen%20Shot%202012-09-16%20at%201.12.57%20PM.png
(Note, even if it's an OSX screenshot, it's Python so it will run on Windows/Linux/OSX! How's that for cross-platform huh?)

pokeMa7as
September 21st, 2012, 09:43 PM
Very nice work m.vit! Is that in github.com?

m.vit
September 29th, 2012, 04:10 PM
Pokemon Bronze is being mantained by me directly, to try out PokeClone's current flexibility, it's easy to add tiletypes like ladders so far, and adding NPC animations even more. Scripts are an easy deal. But no, it's all private for now and is as advanced as PokeClone, everything I've done so far is easy to reproduce in PokeClone vanilla :)

sonicrules1234
October 11th, 2012, 05:27 PM
Hi everyone. I've been hanging out in the IRC channel lately, and have generated some pokemon xml files from firered. It's got pretty much all the info in it besides tm's and hm's.

m.vit
October 12th, 2012, 11:37 AM
[css-div="padding-left:10px; border: 1px solid #000; color: #FFF; text-shadow: 0px 1px 3px #000; background-image: url('https://dl.dropbox.com/u/5191095/gradient.png'); background-repeat: repeat; background-color:#6CBF61; height:40px; line-height: 40px;"]PokeClone Content Update!
[/css-div]
Now this should look fancier, anyways time for the first content update where I'll be showing what's new/recent.

First thing, Sonicrules1234, who posted the awesome xml files for all of the first 251 Pokémon is joining the PokeClone main team! *claps*

Alright, so since the screenshots don't tell much and are kind of outdated (kind of being an understatement) I've decided to record a video!

9pD-ZNcBixo

Now, this is the internal Pokémon Bronze build, so there's a map in there that isn't in the final version, but it should show how easy it was to make a custom movement tile, in this case, climbing ladders.

And finally, here's a gif showing how smooth OpenGL animations are, expect more OpenGL integration soon!
http://img.photobucket.com/albums/v451/maurivit/reuniclus.gif (http://img.photobucket.com/albums/v451/maurivit/reuniclus.gif)
Click on it to see it.

Also, we're looking for an OpenGL coder who can help out on the conversion from SDL, please pm me or go in the channel for more info

DaSpirit
October 12th, 2012, 01:06 PM
Nice to know you got OpenGL working. Does the game render each individual body part like how you wanted?

m.vit
October 12th, 2012, 01:42 PM
Yeah, still supports odd numbers weirdly

Fraot
October 12th, 2012, 01:59 PM
I like the fact that the screenshots are from Mac; which means it runs natively on Mac.

m.vit
October 17th, 2012, 05:28 PM
[css-div="padding-left:10px; border: 1px solid #000; color: #FFF; text-shadow: 0px 1px 3px #000; background-image: url('https://dl.dropbox.com/u/5191095/gradient.png'); background-repeat: repeat; background-color:#6CBF61; height:40px; line-height: 40px;"]PokeClone Content Update! #2
[/css-div]

PokeClone is starting to look more like a game? Why? It's got new content, 251 Pokémon from FireRed and all of FireRed's attacks, however effects haven't been implemented yet...

Here's today's video!
wtLjSK7TvqU

Courtesy of Sonicrules1234!

As you can see we have battles working once more, even trainer battles, a very early move list/attack command, some general tweaking here n' there, the damage formula from Gen.5 is in there too!

So what's next? 1) Implementing all of the Pokemon/Animations from Black/White, start effects/attack animations and 2) implement the battle system with OpenGL... BUT!

We need another developer, tpw_rules is busy most of the time and sonicrules1234 is more of a data manager/converter guy, so if you know a guy who knows a cousin who knows OpenGL, feel free to tell him about this project and join #Pokeclone in FreeNode!

DaSpirit
October 17th, 2012, 05:40 PM
Wow, really nice progress! I can really see this go somewhere.

I wish I could help but I have my own kit to work on. :p