RPG Battle Engine (similar to RPG Maker)

A place for Ren'Py tutorials and reusable Ren'Py code.
Forum rules
Do not post questions here!

This forum is for example code you want to show other people. Ren'Py questions should be asked in the Ren'Py Questions and Announcements forum.
Message
Author
demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

RPG Battle Engine (similar to RPG Maker)

#1 Post by demonangelz »

Hi guys,
I was playing around with renpy and was trying to see if I could make an rpg with purely screen languages and not too much python code. I liked the default RPG maker engine and was trying to imitate that style. So far, I have a basic code that shows how I did everything. The GUI is just a simple one I made but it can be changed easily.
The code itself has comments which I hope will explain how it works. If you need to me add anymore information, I'll be glad to.
This is really simple and doesn't have a lot of features. However, it's to show a basic RPG system and I hope it'll be helpful to you guys.
Current missing:
Animations
Transitions
Ability to change the number of players/party member fighting

If there's anything I did incorrectly, please tell me or if there is any bugs, do tell. The coding I do in renpy is all self taught with a lot of tutorials so I know there might be a traditional or better way to do things that I don't know about.

I attached a couple screenshots below:
ss-capture1.PNG
ss-capture2.PNG
Download from: https://www.dropbox.com/s/g81njii9ejyrt ... e.zip?dl=0
Hope this helps!
Credit me by linking back to this site or look in the credits.txt for alternative ways for crediting. The code is free to change or modify for anyone, you don't need to tell me ^^

quick edit: small change in checking monsters dead parameters, should work fine now!
Last edited by demonangelz on Sat Jan 24, 2015 1:20 am, edited 1 time in total.
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#2 Post by demonangelz »

Quick note, you may have to make the monster3_hp parameter 0 if you only are using only 2 monsters, sorry I will change that in the code so you don't have to do that once I get back on my computer
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

squark
Veteran
Posts: 277
Joined: Fri Aug 17, 2007 9:59 am
Completed: Tour de Pharmacy (Proofreader), The Abandoned Land: Book One (Proofreader)
Projects: Raven Hollow (Core Coder, Proofreader), The Universal Hope (Core Coder, Proofreader)
Organization: FlareBlue Entertainment
Location: Always somewhere behind you...
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#3 Post by squark »

This is lovely, thank you ^^
Without communication, nothing is possible.
"All we see or seem
Is but a dream within a dream.

I stand amid the roar
Of a surf-tormented shore"
-- Edgar Allen Poe, "A Dream Within A Dream"
Current Projects:
Universal Hope Stalled
Raven Hollow (on hold for now)
Peace and Love,
Squark

squark
Veteran
Posts: 277
Joined: Fri Aug 17, 2007 9:59 am
Completed: Tour de Pharmacy (Proofreader), The Abandoned Land: Book One (Proofreader)
Projects: Raven Hollow (Core Coder, Proofreader), The Universal Hope (Core Coder, Proofreader)
Organization: FlareBlue Entertainment
Location: Always somewhere behind you...
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#4 Post by squark »

Okay, so I load this into the launcher and hit launch.
Brings up the main menu, I hit Start and it crashes.
Do I need to update Ren'Py or something?
Without communication, nothing is possible.
"All we see or seem
Is but a dream within a dream.

I stand amid the roar
Of a surf-tormented shore"
-- Edgar Allen Poe, "A Dream Within A Dream"
Current Projects:
Universal Hope Stalled
Raven Hollow (on hold for now)
Peace and Love,
Squark

User avatar
Karen
Newbie
Posts: 19
Joined: Sat Feb 28, 2015 4:25 pm
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#5 Post by Karen »

Have been searching for something like this for a while atleast atleast ATLEAST!!!!!!
found it :lol:

thx anyway

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#6 Post by demonangelz »

@ squark
Sorry for the late reply! Super busy lately >__<
Yeah, I believe you need to update renpy, I'm not having any problems on my side when I launch the game.
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

paktek123
Newbie
Posts: 13
Joined: Thu Jan 01, 2015 8:31 am
Completed: Raiser RPG Framework for Ren'Py
Github: paktek123
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#7 Post by paktek123 »

This is very well done! I love the battle system. I am trying to do something similar too but you have done in a more classical style! My advise (constructive criticism) would be:

- at the moment things are a little too 'hard coded' especially with all the 'if' statements, would be good to turn those into renpy call statements (calling a label with params) or python functions. This way you don't have to put all those 'if' statements.

- If you are going to do a full rpg maker would be great to see an open world aspect too. Emulating the free world with player moving isn't easy and will probably require python code but I suggest you give it a shot!

I don't mind helping out if you need.

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#8 Post by demonangelz »

Hi paktek123,
Thanks! Yeah, this was the first time I coded something in renpy and didn't know about using python functions. But that sounds better and much more abstract, I'll keep that in mind and try it out once things get less busy for me ^^.
I'm not sure how I would go about open world although I think someone has already done something like that in the cookbook. I'll look into it in the future and PM you if I need help :)
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

User avatar
Kokoro Hane
Eileen-Class Veteran
Posts: 1236
Joined: Thu Oct 27, 2011 6:51 pm
Completed: 30 Kilowatt Hours Left, The Only One Girl { First Quarter }, An Encounter ~In The Rain~, A Piece of Sweetness, Since When Did I Have a Combat Butler?!, Piece by Piece, +many more
Projects: Fateful Encounter, Operation: Magic Hero
Organization: Tofu Sheets Visual
Deviantart: kokoro-hane
itch: tofu-sheets-visual
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#9 Post by Kokoro Hane »

This code looks cool, something I definitely need. Curious; what version of Ren'Py do you use? Just wondering, as I wanna make sure if I can sue it on the version I use or if I should use it in a later version.
PROJECTS:
Operation: Magic Hero [WiP]
Piece By Piece [COMPLETE][Spooktober VN '20]
RE/COUNT RE:VERSE [COMPLETE][RPG]
Since When Did I Have a Combat Butler?! [COMPLETE][NaNoRenO2020+]
Crystal Captor: Memory Chronicle Finale [COMPLETE][RPG][#1 in So Bad It's Good jam '17]

But dear God, You're the only North Star I would follow this far
Owl City "Galaxies"

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#10 Post by demonangelz »

Ack sorry I don't check lemma often enough >__< you should be able to run it on an earlier version since I coded this up around January. However, if it doesn't work then you might need to upgrade to the latest version. It's currently running fine for me and I'm have the latest version of Ren'Py.
Feel free to ask if you have any questions or run into any issues with it! :)
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

User avatar
noeinan
Eileen-Class Veteran
Posts: 1153
Joined: Sun Apr 04, 2010 10:10 pm
Projects: Ren'Py QuickStart, Crimson Rue
Organization: Statistically Unlikely Games
Deviantart: noeinan
Github: noeinan
Location: Washington State, USA
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#11 Post by noeinan »

This looks awesome! Do you have a restriction on commercial use?

Also, would it be okay with you if I added this or modified code to my Ren'Py Quickstart (with credit, of course)? (Link: http://lemmasoft.renai.us/forums/viewto ... 51&t=22393 )
Image

Image
Image

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#12 Post by demonangelz »

There's no restrictions at all ^_^ so commercial use is fine! Yep, sure, you can modify it however you like for the quickstart! Glad you found it helpful :D
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

Tentacles
Regular
Posts: 69
Joined: Tue Jul 14, 2009 10:02 pm
Projects: Uploaded Fairy ( Interactive Comic )
Deviantart: otissalmoneus
Github: LWFlouisa
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#13 Post by Tentacles »

Would I be able to open to learn how you did it? I've been looking for something like this for a while.

Mainly I'm wanting it to focus on Attack and Defend. And then maybe add features like distance factor. Which basically means, the more you select that option the greater the distance variable. 1 nullifies your defence, 2 cuts it in half, et cetera until it reaches a max of $distance_factor = 4.

And then some other stuff, like the dynamic of the battle changing based on if you're back attacked or front attacked.

This looks absolutely excellent though.
I develop horror romance interactive comics. Currently working on my first.

demonangelz
Regular
Posts: 51
Joined: Tue Aug 23, 2011 10:19 am
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#14 Post by demonangelz »

Hi! Yes, the code is totally open for you to look into it and see how everything is done. Not sure about your question but I think distance is possible to incorporate? I haven't done that before so I'll have to look into it myself but the code is free for you to modify in any way you want so youcan always play around with it! XD
I have returned after a long time away. Working on a small project, hope I'll be able to show it on here soon! =D

fah-renheit
Newbie
Posts: 9
Joined: Tue Sep 22, 2015 12:34 pm
Deviantart: fah-renheit
Skype: yl_sumitr
Contact:

Re: RPG Battle Engine (similar to RPG Maker)

#15 Post by fah-renheit »

Thank you so much for providing us a free battle engine!
Thank you again!!

Post Reply

Who is online

Users browsing this forum: No registered users