Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Please Help me with advice? PLEASE! THANKS!
- IceDiamond
-
9 posts
Please Help me with advice? PLEASE! THANKS!
Hello,
I really like RPG games because of their story and cut scenes, but, I just have a couple problems. I can't figure out how to make cut scenes, enemy health, character health, money, and stuff like that. I also don't know how to make the bad guys work with a scrolling screen. If you have any tips, scripts or advice you would like to share, I would really appreciate it a lot.
Thanks!
Your Fellow Scratcher.

I really like RPG games because of their story and cut scenes, but, I just have a couple problems. I can't figure out how to make cut scenes, enemy health, character health, money, and stuff like that. I also don't know how to make the bad guys work with a scrolling screen. If you have any tips, scripts or advice you would like to share, I would really appreciate it a lot.
Thanks!
Your Fellow Scratcher.

- drmcw
-
1000+ posts
Please Help me with advice? PLEASE! THANKS!
Sounds like everything! Why not find an RPG project you like then use the see inside button. You should learn a lot from doing that. If any particular scripts stump you then ask back on here for further help.
- DanloVorje
-
100+ posts
Please Help me with advice? PLEASE! THANKS!
Wow! A lot of stuff to cover. I'll probably do multiple posts to try and help you with this.
TOPIC ONE: CUTSCENES
My preferred method for cutscenes is to make extensive use of broadcast blocks. I set up my scripts with one of three main headers:
BEGIN_GAME runs a script right at the start of the game in order to handle any game data that needs to be reset each time the player starts a new game (starting position, inventory, etc).
PLAY runs the scripts that involve actual gameplay, but does not reset any game data.
CUTSCENE starts a cutscene. Since “When I receive CUTSCENE” is immediately followed by a “stop other scripts in this sprite” block, the project will stop running PLAY scripts while the cutscene is happening. The cutscene script ends with
This setup makes it easy to add other modes, such as menus and pauses, by making more scripts starting with “When I receive ______” followed by “stop other scripts in this sprite”.
Basically the idea is to separate the scripts that you can be restarted without affecting gameplay (When I receive PLAY) from the ones that should only run once in the course of the game (When I receive BEGIN_GAME).
As for the actual cutscene, it can be anything from a simple sequence of “next costume” blocks to something more complicated with animated sprites moving around.
Hope this helps! If you have more questions, just ask. I'll cover health, money, and inventories next.
–Danlo
TOPIC ONE: CUTSCENES
My preferred method for cutscenes is to make extensive use of broadcast blocks. I set up my scripts with one of three main headers:
BEGIN_GAME runs a script right at the start of the game in order to handle any game data that needs to be reset each time the player starts a new game (starting position, inventory, etc).
PLAY runs the scripts that involve actual gameplay, but does not reset any game data.
CUTSCENE starts a cutscene. Since “When I receive CUTSCENE” is immediately followed by a “stop other scripts in this sprite” block, the project will stop running PLAY scripts while the cutscene is happening. The cutscene script ends with
So that the game starts running again when the cutscene is over.
This setup makes it easy to add other modes, such as menus and pauses, by making more scripts starting with “When I receive ______” followed by “stop other scripts in this sprite”.
Basically the idea is to separate the scripts that you can be restarted without affecting gameplay (When I receive PLAY) from the ones that should only run once in the course of the game (When I receive BEGIN_GAME).
As for the actual cutscene, it can be anything from a simple sequence of “next costume” blocks to something more complicated with animated sprites moving around.
Hope this helps! If you have more questions, just ask. I'll cover health, money, and inventories next.
–Danlo
- DanloVorje
-
100+ posts
Please Help me with advice? PLEASE! THANKS!
A pointer to go with @drmcw's suggestion:
http://scratch.mit.edu/projects/583768/
This was an example project included with Scratch 1.4. I learned quite a bit from looking inside and modifying this project back when I started using Scratch. It doesn't cover everything you're asking about, but the scripting is pretty easy to understand and it's a nice base to work off of.
http://scratch.mit.edu/projects/583768/
This was an example project included with Scratch 1.4. I learned quite a bit from looking inside and modifying this project back when I started using Scratch. It doesn't cover everything you're asking about, but the scripting is pretty easy to understand and it's a nice base to work off of.
- SuperSmashScratch
-
1000+ posts
Please Help me with advice? PLEASE! THANKS!
There's a wiki tutorial, I think. For enemy health and character health, there's a page called Turn-based RPG.
- datdudeiscodingTR
-
2 posts
Please Help me with advice? PLEASE! THANKS!
my problem is that i want if it touches an object, i want it to switch to another costume
- lwell72
-
100+ posts
Please Help me with advice? PLEASE! THANKS!
For the enemies you will have to make clones.Make a variable called Enemy Health and SET IT TO THIS SPRITE ONLY
That way each clone has its own health.
For the money make a money variable. Make it so each time you kill an enemy it will make the coins go up. The enemy will die if it’s health is below 1.
For the player health just make another health variable, it does not have to be for this sprite only.
If the enemy bulet is touching the player it will decrease the players health.
I have a cool shooter game that you might find fun.
Just down below in my signature.
Take it look and be inspired! Hope you like it and get good ideas for your game!
That way each clone has its own health.
For the money make a money variable. Make it so each time you kill an enemy it will make the coins go up. The enemy will die if it’s health is below 1.
For the player health just make another health variable, it does not have to be for this sprite only.
If the enemy bulet is touching the player it will decrease the players health.
I have a cool shooter game that you might find fun.
Just down below in my signature.
Take it look and be inspired! Hope you like it and get good ideas for your game!
Last edited by lwell72 (May 7, 2018 00:41:54)
- Discussion Forums
- » Help with Scripts
-
» Please Help me with advice? PLEASE! THANKS!