Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

turned based fighting example #121

Closed
14 tasks done
shadow00dev opened this issue Sep 26, 2021 · 181 comments
Closed
14 tasks done

turned based fighting example #121

shadow00dev opened this issue Sep 26, 2021 · 181 comments
Labels
✨ New example A new example

Comments

@shadow00dev
Copy link

shadow00dev commented Sep 26, 2021

Describe the example

this is a turned based fighting example game with 1 player and enemy with 2 ability(fireball and summon zombie) also i made the art myself

heres a link to play it: https://shadow001.itch.io/turned-based-fighting-example

Checklist

  • My game has all events unfolded.
  • My game has a proper name in the game properties.
  • I've added myself as the author in the game properties.
  • I've included a file called "README.md" with a description in proper English, explaining what this example is doing.
  • I confirm that this game and all of its resources can be integrated to this GitHub repository, distributed and MIT licensed.
  • My game package name behind with com.example..
  • I've cleaned unused resources.
  • Resources
  • Game properties
  • Objects
  • UI/scene layout
  • FSM
  • Unused events
  • Factorize events

(the project folder is in comments)

@shadow00dev shadow00dev changed the title New example turned based fighting example Sep 26, 2021
@D8H
Copy link
Contributor

D8H commented Sep 28, 2021

Thank you for sharing this example.
I only took a quick look at the events. It seems that a FSM could make the events a lot clearer. This tutorial might help you:
http://wiki.compilgames.net/doku.php/gdevelop5/tutorials/finite_state_machine

Can you explain what concepts this example will bring to light?
I guess you wanted to show something like the FSM, but I only took a quick glance.

@shadow00dev
Copy link
Author

Thank you for sharing this example. I only took a quick look at the events. It seems that a FSM could make the events a lot clearer. This tutorial might help you: http://wiki.compilgames.net/doku.php/gdevelop5/tutorials/finite_state_machine

Can you explain what concepts this example will bring to light? I guess you wanted to show something like the FSM, but I only took a quick glance.

theres 1 animation for player 1 for enemy and 1 for zombie i would of assume i wouldn't need a FSM also i made this because someone asked for help on gdevelop discord a turned based game, and i realized gdevelop don't have a example so i made a example for gdevelop

@D8H
Copy link
Contributor

D8H commented Sep 29, 2021

theres 1 animation for player 1 for enemy and 1 for zombie i would of assume i wouldn't need a FSM

The tutorial takes platformer animations as an example, FSM can be used for everything that need states. In the case of this example it could be:

  • Wait user action
  • Play player attack animation
  • Play opponent attack animation
  • Game over

It avoids to have the same condition repeated everywhere and make it clear what happens in each state.

But, maybe wait to have someone else opinion before doing changes because even though it could be a good template, I don't think it has its place as an example.

@Bouh
Copy link
Contributor

Bouh commented Sep 29, 2021

My first opinion when I saw the game is how to play it?

There are texts on the screen, but I don't understand directly what I can do.
It's a problem with graphics and layout, you might be using the graphic assets from the asset store to make a more attractive game with a consistent style.

An FSM is welcome yes.
It allows having whole logic in groups, and better readability of the event sheet when logic is separate.

@Bouh
Copy link
Contributor

Bouh commented Sep 29, 2021

What I spotted:

  • Objects aren't all in PascalCase
  • Variables name format is fancy, by convention prefer using PascalCase. e.g: Aility_use -> AilityUse (is there a typo? It should be Agility?)
  • I can see an empty parameter in the event sheet, even if this value is optional we fill every field, otherwise, an error appears in red. For an example we can not afford it, they must be almost perfect ;),
  • Not sure this format can be accepted on PlayStore com.example.turned_based_fighting

Art folder is great, nice to see this, it's a must to have, same for the readme :) !

@shadow00dev
Copy link
Author

shadow00dev commented Sep 29, 2021

okay

@shadow00dev
Copy link
Author

shadow00dev commented Sep 29, 2021

It's a problem with graphics and layout, you might be using the graphic assets from the asset store to make a more attractive game with a consistent style.
I understand this I just made my own art because I don't like using another people art(I know I'm not the best are making art) if I must 95% have to change it to some on the asset store I will, also I think its the grass that makes it inconsistent right, maybe I should try and do a alien grass thing instead(cuz the player and enemy don't look human)?, also with FSM I think I might not do that if 98% needed as well because there's not a lot of animations per object

@shadow00dev
Copy link
Author

theres 1 animation for player 1 for enemy and 1 for zombie i would of assume i wouldn't need a FSM

The tutorial takes platformer animations as an example, FSM can be used for everything that need states. In the case of this example it could be:

  • Wait user action
  • Play player attack animation
  • Play opponent attack animation
  • Game over

It avoids to have the same condition repeated everywhere and make it clear what happens in each state.

But, maybe wait to have someone else opinion before doing changes because even though it could be a good template, I don't think it has its place as an example.

well i know I cant say this but I personally think this could help people with basics of some stuff In gdevelop and if anyone ever need help with making a turned based fighting system my example could help(it helped the person it was originally made for)

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip
the only changes I haven't done is FSM and didn't use the asset store but I did change the art a little(hard to notice player and enemy changes in game but zombie change you will notice)

@D8H
Copy link
Contributor

D8H commented Sep 29, 2021

But, maybe wait to have someone else opinion before doing changes because even though it could be a good template, I don't think it has its place as an example.

well i know I cant say this but I personally think this could help people with basics of some stuff In gdevelop and if anyone ever need help with making a turned based fighting system my example could help(it helped the person it was originally made for)

It's totally alright. I just didn't want to make you work on it without the validation of someone that is more used to review examples (like Bouh).

@shadow00dev
Copy link
Author

shadow00dev commented Sep 29, 2021

But, maybe wait to have someone else opinion before doing changes because even though it could be a good template, I don't think it has its place as an example.

well i know I cant say this but I personally think this could help people with basics of some stuff In gdevelop and if anyone ever need help with making a turned based fighting system my example could help(it helped the person it was originally made for)

It's totally alright. I just didn't want to make you work on it without the validation of someone that is more used to review examples (like Bouh).

i would of probably done it anyway(for the itch.io page to make it better) but okay, also this is the first time for this and I haven't done game dev in about a year and then i see that someone needed help i made a "crappy" example for him then made this one cuz i wanted to make it better so this is it i guess, also I'm not that good at explaining stuff to tbh(like for example if I have a story idea I'm not good and showing it in a good way)

@Bouh
Copy link
Contributor

Bouh commented Sep 30, 2021

The idea of a Start scene is interesting.
I was thinking about a redesign of the presentation to make the project more attractive.
I strongly suggest using objects/textures from the asset store because there are icons and buttons.
It gives a style and a certain cachet to the example.
If you want my personal opinion, it is not presentable. That's why I'm pushing to have a minimum interface with sprites from the asset store.

the only changes I haven't done is FSM and didn't use the asset store but I did change the art a little

I'm probably annoying, but the quality is essential. An example should be representative of the software and the games that are possible.

I see that you have indeed made some changes, continue the changes, it's on the right track!

  • I see that there is at least one object not used, it has a default name.
  • Click to start, is not centred.
  • Use groups in the events, it makes the project much more structured.
  • Put capital letters at the beginning of sentences, especially in the comments.
  • There are two objects in lowercase while the others are in PascalCase, unify them in PascalCase, a project with coherence makes it immediately more professional.
  • Between the rounds, there is no waiting time. It's that goes immediately to the enemy, if you don't want to put a pause time, I understand. In this case, set in the centre of the screen that it's now the enemy's or the player's turn, display it for a few seconds and hide it.
    You will say it is ridiculous it is already displayed, yes, but that does not present as a game, it is not ludic. An example after presenting a feature also presents a type of game. I think that this example lacks the basics of the information that can have a turn-based game.

i would of probably done it anyway(for the itch.io page to make it better) but okay, also this is the first time for this and I haven't done game dev in about a year and then i see that someone needed help i made a "crappy" example for him then made this one cuz i wanted to make it better so this is it i guess, also I'm not that good at explaining stuff to tbh

I don't want to sound mean, I know there is a desire to do well and help others by posting this example. It's also my goal, to have an example project that looks pro and is consistent with what it promises, then that is pleasant to play and see while respecting a minimum of turn-based games standards.

I don't do feedback like that to hurt people, but to have a higher and more professional quality level.
Don't take it personally, it's just a review of a project.
I would be happy to continue the feedback with you in order to have a final rendering that I could accept without any problem in accordance with the required quality level.

@shadow00dev
Copy link
Author

The idea of a Start scene is interesting. I was thinking about a redesign of the presentation to make the project more attractive. I strongly suggest using objects/textures from the asset store because there are icons and buttons. It gives a style and a certain cachet to the example. If you want my personal opinion, it is not presentable. That's why I'm pushing to have a minimum interface with sprites from the asset store.

the only changes I haven't done is FSM and didn't use the asset store but I did change the art a little

I'm probably annoying, but the quality is essential. An example should be representative of the software and the games that are possible.

I see that you have indeed made some changes, continue the changes, it's on the right track!

  • I see that there is at least one object not used, it has a default name.
  • Click to start, is not centred.
  • Use groups in the events, it makes the project much more structured.
  • Put capital letters at the beginning of sentences, especially in the comments.
  • There are two objects in lowercase while the others are in PascalCase, unify them in PascalCase, a project with coherence makes it immediately more professional.
  • Between the rounds, there is no waiting time. It's that goes immediately to the enemy, if you don't want to put a pause time, I understand. In this case, set in the centre of the screen that it's now the enemy's or the player's turn, display it for a few seconds and hide it.
    You will say it is ridiculous it is already displayed, yes, but that does not present as a game, it is not ludic. An example after presenting a feature also presents a type of game. I think that this example lacks the basics of the information that can have a turn-based game.

i would of probably done it anyway(for the itch.io page to make it better) but okay, also this is the first time for this and I haven't done game dev in about a year and then i see that someone needed help i made a "crappy" example for him then made this one cuz i wanted to make it better so this is it i guess, also I'm not that good at explaining stuff to tbh

I don't want to sound mean, I know there is a desire to do well and help others by posting this example. It's also my goal, to have an example project that looks pro and is consistent with what it promises, then that is pleasant to play and see while respecting a minimum of turn-based games standards.

I don't do feedback like that to hurt people, but to have a higher and more professional quality level. Don't take it personally, it's just a review of a project. I would be happy to continue the feedback with you in order to have a final rendering that I could accept without any problem in accordance with the required quality level.

I don't take it personally, also okay ill get to work on changes

@shadow00dev
Copy link
Author

also i do use groups in the project to structure it btw(well I structure it different prob but I do use them for that reason)

@Bouh Bouh added the ✨ New example A new example label Sep 30, 2021
@Bouh
Copy link
Contributor

Bouh commented Sep 30, 2021

also i do use groups in the project to structure it btw(well I structure it different prob but I do use them for that reason)

You can add groups, for white comments ;)
Think major caps at beginning of the sentences in groups/comments.

@shadow00dev
Copy link
Author

also i do use groups in the project to structure it btw(well I structure it different prob but I do use them for that reason)

You can add groups, for white comments ;) Think major caps at beginning of the sentences in groups/comments.

okay

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip
here it is the only thing i did to is say the turn in the center of scene(mainly because when i tried it was very buggy and it made no sense to me to why(because it was happening even when i told it not to))

@shadow00dev
Copy link
Author

shadow00dev commented Sep 30, 2021

TurnedBasedFighting.zip
sorry for another upload but i find a issue with the last one(ik i should of checked and i did maybe the tired got to me then but when i realised i fixed the issue(issue was 2 images that were not used were there)), hopefully this is updated to be to the liking

@shadow00dev
Copy link
Author

@Bouh sorry for pinging you but i got told to ping the person who was reviewing it and i think it was you so um may i ask for you to check if there are any issues with it again please i did all the changes you asked i belive

@D8H
Copy link
Contributor

D8H commented Oct 20, 2021

I took a quick look.

The buttons for touch devices are nice. I think you could use it for computer too. They could be used to make the player understand when an input is expected from him. For instance, using an orange/green tint on the one selected and a half opacity on the other.

The enemy health should probably be the enemy side. I think it could be nice to have a health bar instead. It can be done by changing the width of a tiled sprite for instance.

You didn't do the FSM. We can help you to do it step by step if you want. The 1st step is to put every event that has the condition Turn = "Player" as sub event of an event with this condition and same with Turn = "Enemy". It avoid to repeat this condition everywhere and give more structure.

@shadow00dev
Copy link
Author

I took a quick look.

The buttons for touch devices are nice. I think you could use it for computer too. They could be used to make the player understand when an input is expected from him. For instance, using an orange/green tint on the one selected and a half opacity on the other.

The enemy health should probably be the enemy side. I think it could be nice to have a health bar instead. It can be done by changing the width of a tiled sprite for instance.

You didn't do the FSM. We can help you to do it step by step if you want. The 1st step is to put every event that has the condition Turn = "Player" as sub event of an event with this condition and same with Turn = "Enemy". It avoid to repeat this condition everywhere and give more structure.

first 2 i will do, but i got told i didn't need to do fsm(also yah i don't feel like doing fsm cuz well I'm not used to it and I've ordered my events in a way where a fsm would prob be worse?)

@shadow00dev
Copy link
Author

also for fsm if i do, do it then should i make a group and put it there maybe

@Bouh
Copy link
Contributor

Bouh commented Oct 20, 2021

There are good changes, this example has style!

  • Resources
  • Game properties
  • Objects
  • UI/scene layout
  • FSM
  • Unused events
  • Factorize events

Review

  • Avoid as possible stretch sprites, e;g: Start button
  • Num 1 and 2 are maybe not great inputs, I agree with D8H, the button for mobile are quite better and can be used for desktop too. Try it on the desktop and adapt the event on buttons for start the action when the button is clicked.
  • About FSM, this isn't complex, you almost did it by grouping events and comments.
    The principle behind FSM is similar, partitioning the states so that they don't mix and affect each other, otherwise, most of the time creates unexpected bugs.
  • As the Player is always the first to start, the Enemy can't won, not a bug deal but in this case there is unused events.
  • Flip variable, and Flip events are not all neccesary, you can remove it, this dosen't add value in this example.
    You need it once at begnning of the scene for flipping the animations of the Enemy, no more. For the Fireball and the Monster you have to keep one action in one direction, no need to handle -180 and 180 angle for Fireball and force -100 and 100 for Monster, This way there is no need to adds conditions for checking if an object is flipped. You have just Turn enemy = true, AbilityUse = Fireball, then create Fireball, and add a force toward Player position. (or -180 angle if you prefer)

@shadow00dev
Copy link
Author

shadow00dev commented Oct 20, 2021

FSM I will do I guess, though I'm pretty sure there aren't any unused events? , also it's possible for the player to lose, also btw I just finished the first step of doing the FSM(well I did what D8H said to do(which was step 1 I think idk), also for the flip events they're there so it can be changed when ever wanted from the scene

@shadow00dev
Copy link
Author

shadow00dev commented Oct 20, 2021

TurnedBasedFighting.zip

here is the update with the changes the only thing I didn't change is the flip event stuff since I personally think it would be more helpful for some stuff(like if someone wanted to edit the level or add their own they could use the flip event to change the player and enemy around or something I guess), and with the FSM I did it from how I understood it from the link(i didn't use the external events though)

@D8H
Copy link
Contributor

D8H commented Oct 20, 2021

There is a typo (game) in the Game variable. This variable could be a new state.

You added 2 states with the Turn variable. You can rename this variable State and use the values "PlayerTurn" and "EnemyTurn". This way new states can be added like GameOver. This state will replace the Game variable. You'll probably need to move the event that changes the Stats inside the "PlayerTurn" and "EnemyTurn" state.
After that we will try to replace the PlayerUsedAbility variable. The idea is to reduce the number of variables that represents the state to have each state clearly delimited.

I meant green/orange as green = zombie and orange = fire to show the button is active.

@shadow00dev
Copy link
Author

There is a typo (game) in the Game variable. This variable could be a new state.

You added 2 states with the Turn variable. You can rename this variable State and use the values "PlayerTurn" and "EnemyTurn". This way new states can be added like GameOver. This state will replace the Game variable. You'll probably need to move the event that changes the Stats inside the "PlayerTurn" and "EnemyTurn" state. After that we will try to replace the PlayerUsedAbility variable. The idea is to reduce the number of variables that represents the state to have each state clearly delimited.

how could i replace the playerusedabitly?, cuz the "State" wouldnt be able to do that cuz of how the system would work right? cuz the "State" was only meant to be a "Turn" orginally

I meant green/orange as green = zombie and orange = fire to show the button is active.

ooh okay

@shadow00dev
Copy link
Author

@D8H can you please give a list of stuff for me to do with polishing please(i know i pinged you again and sorry, but sometimes i get worried and Want to finish it as soon as possible(hence why i try to answer as quickly and i can) i do find working on this fun but i dont know what else to do maybe remove the info text but that's all i can really think off)

@Midhil457
Copy link
Contributor

Midhil457 commented Nov 2, 2021

Hi, I can't do a full review cuz I am not on my system and having to use the web app, which for some reason can't load the resources and I have some limitations with time :(. (I haven't gone through the 156 message 😱, so some of them might be already suggested)

  • The package name should be com.gdexample.<projectname> as all the example's package name was recently updated to use that format to prevent any conflicts
  • The desktop icons seems to be the same as the thumbnail image. But, a separate image is used. You can use the thumbnail for the icon too
  • CenterX() and CenterY() is now preferred more than PointX("center") and PointY("center")

trn-3

  • This format should in theory work as the mouse conditions are compatible with a touch screen
    trn-1
  • What is the use of picking all PlayControls here?
    trn-2

:)

@shadow00dev
Copy link
Author

okay and for the pick all condition, idk tbh, originally i changed both button but this doesn't

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip

Screenshot 2021-11-02 185842

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip

fixed the 2 images not being in the right place and removed red text stuff from resource tab

@shadow00dev
Copy link
Author

shadow00dev commented Nov 4, 2021

@D8H please can I ask for you to tell me what to change(cuz really wanna get this finished and umm idk), and yes i know i sound super inpatient but i cant help it(and sorry)

@D8H
Copy link
Contributor

D8H commented Nov 4, 2021

I'm working on the platformer behavior. I'll try to take a look in a few days.

@shadow00dev
Copy link
Author

okay

@D8H
Copy link
Contributor

D8H commented Nov 4, 2021

  • I made a typo in this comment: "Marck [Mark] a pause before choosing an attack"
  • The text color could be the same hue as a color from the back ground. For instance, the blue of the moon holes is ABD7FF.
  • The game over mask opacity can be raised to 196 to have enough contrast with the text.
  • Characters should be about the same distance from the center of the screen. Maybe nearer to the center than currently.
  • The health bar color is really flashy. I could be a bit darker and less saturated.

@shadow00dev
Copy link
Author

shadow00dev commented Nov 4, 2021

  • I made a typo in this comment: "Marck [Mark] a pause before choosing an attack"

so like i show a pause?, okay

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip
Screenshot 2021-11-04 215407

@D8H
Copy link
Contributor

D8H commented Nov 4, 2021

  • I made a typo in this comment: "Marck [Mark] a pause before choosing an attack"

so like i show a pause?, okay

  • It's just a "c" to remove in a comment from EnemyChoice.
  • The health bar is hard to see now. Maybe this color: b41818?
  • The buttons should probably be under the character like before.

@shadow00dev
Copy link
Author

  • The buttons should probably be under the character like before.

i never changed the position of them :|

  • It's just a "c" to remove in a comment from EnemyChoice.

sorry idk what that means, i remove "c from comment?, ill check them to see if i can understand

  • The health bar is hard to see now. Maybe this color: b41818?

okay

@shadow00dev
Copy link
Author

Screenshot 2021-11-05 145514

for mobile at least i personally would hate playing it like this tbh(the controls were where i put them cuz its nice and easzy to touch them on mobile devices) i will only do it if you want me to and i mean like if you say do it (not a maybe do it cuz i dont like it so i dont really want to but i will if you tell me)

@shadow00dev
Copy link
Author

  • It's just a "c" to remove in a comment from EnemyChoice.

ooh i see now ill give you thefiles for the changes as soon as i can(like right now almost) but i didnt change pos of buttons since i dont like the idea of it personnally

@shadow00dev
Copy link
Author

TurnedBasedFighting.zip

Also Sorry for super late aswer i was asleep then i think(or didnt check github)

all i changed was color of health bar to b41818
and remove c from marck in the comment inside enemychoice

@Midhil457
Copy link
Contributor

Hi, sorry I can’t do a proper review. But,
See if your example follows the best practices, http://wiki.compilgames.net/doku.php/gdevelop5/community/guide-for-submitting-an-example#best_practices
Don’t know if someone already suggested it in the 157 message so 😅

@shadow00dev
Copy link
Author

Hi, sorry I can’t do a proper review. But, See if your example follows the best practices, http://wiki.compilgames.net/doku.php/gdevelop5/community/guide-for-submitting-an-example#best_practices Don’t know if someone already suggested it in the 157 message so 😅

i have read this before and i think when doing the major changes in event it was kinda(unkownly) following it(well if i remeber correctly)

@Midhil457
Copy link
Contributor

Midhil457 commented Nov 8, 2021

Hi, I wasn't able to find much issues. but, there are a few that I missed from the last review (sorry btw for missing them), Great project btw

  • The README this is a turned based fighting example game, this example game works on mobile and computer also, this example uses assets from Kenney and pzUH, sound effects made with bfxr, and music made with chrome music lab could be changed to A simple turn based fight game where the player battles with a bot and the long description being The example works on both on a mobile and a computer. The example uses assets from kenney.nl assets and pzUH. The Sound effects are made using bfxr and chrome music lab. You can add a long description by leaving a space between the short and long description
  • This is just a suggestion, for the flash effect, you could use the flash extension instead of using events to make the events simpler
  • You add spaces in the project name
  • A mistake on my behalf, the package name should be com.example and not as what I suggested, this is more preferred. I am extremely sorry for the mistake 😓

:)

@shadow00dev
Copy link
Author

shadow00dev commented Nov 8, 2021

  • This is just a suggestion, for the flash effect, you could use the flash extension instead of using events to make the events simpler
  1. last time i used that extension is was not working for me

  2. i thought the less extensions the better

  3. im also not a giant fun of using extensions

  4. i think its easy to do??

if you still want me to do it i will

for the rest, okay also im not good at typing stuff and that so um yah(may i use what you put to put in readme?), also sorry for late aswer

@Midhil457
Copy link
Contributor

Midhil457 commented Nov 8, 2021

Yes, feel free to use the one I suggested in the readme

@shadow00dev
Copy link
Author

Thanks :)

@shadow00dev
Copy link
Author

Turned Based Fighting.zip

i didnt do the flash extension thing(for the reasons i told in the reply so ask me to do it if you still want me to)

@Midhil457
Copy link
Contributor

Hi,
I have made a few changes to the project (like changed project's name to Turn Based Fighting and more) and submitted a PR.

Thank you for the great example!

@shadow00dev
Copy link
Author

okay thanks

@Bouh
Copy link
Contributor

Bouh commented Nov 17, 2021

Closed by #165

@Bouh Bouh closed this as completed Nov 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ New example A new example
Projects
None yet
Development

No branches or pull requests

5 participants