-------------------------------------------------------------------------
-----------Pete's Advanced Cooking System-----------
-------------------------------------------------------------------------
Introduction
You might be asking "What's so advanced with this cooking system?". Well, it's just not your regular cooking skill system. What really makes it special is the fact that the cooking chance is calculated and the player can improve the skill.
Before reading the rest of the tutorial
I am not a good teacher, but I'll try to make it as easy as possible for you to understand how the system works and how to create it in your game. If you encounter any dificulties understanding the tutorial or the system, please do post.
Features
I made this system based of World of Warcraft's cooking skill, so you may notice several similarities, don't post about it please.
Real cooking skill, you can improve your cooking skill by successfuly cooking food.
Realistic cooking, the chance of cooking is calculated through the dificulty of the food and the current skill level.
Training and recipes, the player will need to ask an NPC to teach him how to cook (increasing the cooking level cap) and to teach him cooking recipes.
Bad Stuff
Involves some time creating it and can be very boring, maybe it's just easier to make a script and copy paste it. Well whatever...Just leave if you are not willing to waste some time on this.
--------------------------------------------
Essencial stuff
Now that you know what this system provides, as a game maker you will need to know what variables, switches and items you will need to create before starting with the events.
You should decide how many foods (fishes, meats, etc...) your game will have. Now that you made a list, you are going to create 1 switch for each food and name them accordingly (If there will be cookable trouts, you will need a switch named Trout or CookTrout, whatever you want to name it).
Done? Good. Now for each food create 2 items, the raw food and the cooked food. Make sure the raw food heals waaay less than the cooked food and is worth less. Example: A trout will need to have an item named Raw Trout and an item named Trout.
Done already? You're fast. Now lets move to the variables. Create the following variables:
0001: CookingQuantity
0002: CookSkill
0003: CookSkill2
0004: CookSkillXP
0005: CookskillXP2
0006: RandomCheck
0007: CookSkillLimit
And then create the rest of the variables that will be the dificulty levels of cooking. For example, a trout will be at level 1 dificulty to be cooked which means it's easy to cook it. You can have as much dificulty levels as you want, just don't exagerate.
0008: Dificulty1
(...)
0009: DificultyXP
Having the Switches and the Variables set, let's start eventing.
Eventing
You will need 4 common events for this system. More if you want to have things organized (A common event for cooking fish, a common event for cooking meat, etc...).
001: CookStart
-Optional-
002: CookFish
003: CookMeat
004: CookVegetables
-Optional- (You can replace these by only 1 if you want, but I highly recommend you to have things this way)
005: CookSkill
006: CookBook (yeah book, you will see why...)
Now let's start, base your first common event, CookStart on this one:
Easy wasn't it? Now let's burn your brain cells.
But before, you need to know that the cooking will work based on dificulty. For example, dificulty 1 will be very easy to cook and will give the lowest amount of XP.
--------------------------------------------
Make the cooking common event, CookFish in this demo, based on this one:
Notes: The cooking action will be performed as a loop until there is no more of that particular food to cook. It's easy to add a way for the player to choose how much he wants to cook, but I decided not to do that in this demo. You must decide a dificulty level for each food, so when cooking it will use the right variable and give the player the correct amount of experience points.
Done? Now you just have to copy the first whole branch and paste it throughout the 3 common events, but changing the values at the same time, ofcourse.
...
...
...
Finally, you completed it. Cheer up, you have just completed the most sucky part! But, you still don't understand how it is done?
Well, Dificulty1 has the value of 10000, multiplied by the cooking skill (level 1) equals 10000. Then it is divided by 100 which equals 100. Then we get a random value from 1 to 100. If the division is bigger or equal to the random value we have a success, so it means we have a 100% success chance. If dificulty was 5000, divided by 100 equals 50 and we have a 50% chance of success, got it? GOOD!
--------------------------------------------
Now lets do the CookSkill common event.
Create a common event based on this one:
Notes: Here you will have to change the values in order to customize the dificulty of the Skill for your game. CookSkill is the Level, CookSkillXP is the current experience points and CookSkillXP2 is the current Skill's experience points cap, which means that when the CookSkillXP reaches the same value of CookSkillXP2, CookSkill is increased by 1.
Done? Now lets do the CookBook common event.
--------------------------------------------
Create a common event based on this one:
Notes: It's just a common event that will give the player some information about his cooking skill: known recipes, level and experience points. You can call this common event through a key or through an event placed on a map (a book on a table for example)
Done. Let's move to the map events.
--------------------------------------------
Here is a screenshot of a kitchen, very simple but still a kitchen with a sailor in it for some reason.
The sailor is the trainer and you will create this event based on the following:
Notes: This event has 2 pages. Make sure you check the triggering options. In this event you will set up the dificulty level variables. Here is how you will do it: dificulty level 1 value must be equal to 10000, level 2 equal to a value under 10000, since 10000 is the 100% success rate. Every value above will also be 100%.
Page 1:
Page 2:
Now the CookStart common event will be called in that cooking table.
The book has an event to call the CookBook common event.
--------------------------------------------
And that concludes it! (told you I am a bad teacher)
Further Reading
I appreciate your replies and comments, good or bad , so please, start writing! :p
If you find any flaws with the system, broken links/images or any other problem with this tutorial, posts.
I certainly won't explain you how to event, other people can help you with that, just not me.
This has been tested and it works, if it doesn't work for some reason, post a detailed description of the problem and I'll tell you what you have done wrong.
Don't post something stupid in this thread, please.
Get the demo *here*!
Credits:
Created entirely by me (based on World of Warcraft) and a crucial part by MarineMechx2 (thank you very much).
Thanks to:
The people who cared to help me at the General Support, thanks.
What MAY come from me in the future:
Advanced Gathering Skill
-Pete
Updates:
-Fixed the dificulty variable values. (forgot to change them before posting, go check them again..)
-Fixed the values again (if you were wondering why something was not right, try reading the dificulty values explanation again)
-----------Pete's Advanced Cooking System-----------
-------------------------------------------------------------------------
Introduction
You might be asking "What's so advanced with this cooking system?". Well, it's just not your regular cooking skill system. What really makes it special is the fact that the cooking chance is calculated and the player can improve the skill.
Before reading the rest of the tutorial
I am not a good teacher, but I'll try to make it as easy as possible for you to understand how the system works and how to create it in your game. If you encounter any dificulties understanding the tutorial or the system, please do post.
Features
I made this system based of World of Warcraft's cooking skill, so you may notice several similarities, don't post about it please.
Real cooking skill, you can improve your cooking skill by successfuly cooking food.
Realistic cooking, the chance of cooking is calculated through the dificulty of the food and the current skill level.
Training and recipes, the player will need to ask an NPC to teach him how to cook (increasing the cooking level cap) and to teach him cooking recipes.
Bad Stuff
Involves some time creating it and can be very boring, maybe it's just easier to make a script and copy paste it. Well whatever...Just leave if you are not willing to waste some time on this.
--------------------------------------------
Essencial stuff
Now that you know what this system provides, as a game maker you will need to know what variables, switches and items you will need to create before starting with the events.
You should decide how many foods (fishes, meats, etc...) your game will have. Now that you made a list, you are going to create 1 switch for each food and name them accordingly (If there will be cookable trouts, you will need a switch named Trout or CookTrout, whatever you want to name it).
Done? Good. Now for each food create 2 items, the raw food and the cooked food. Make sure the raw food heals waaay less than the cooked food and is worth less. Example: A trout will need to have an item named Raw Trout and an item named Trout.
Done already? You're fast. Now lets move to the variables. Create the following variables:
0001: CookingQuantity
0002: CookSkill
0003: CookSkill2
0004: CookSkillXP
0005: CookskillXP2
0006: RandomCheck
0007: CookSkillLimit
And then create the rest of the variables that will be the dificulty levels of cooking. For example, a trout will be at level 1 dificulty to be cooked which means it's easy to cook it. You can have as much dificulty levels as you want, just don't exagerate.
0008: Dificulty1
(...)
0009: DificultyXP
Having the Switches and the Variables set, let's start eventing.
Eventing
You will need 4 common events for this system. More if you want to have things organized (A common event for cooking fish, a common event for cooking meat, etc...).
001: CookStart
-Optional-
002: CookFish
003: CookMeat
004: CookVegetables
-Optional- (You can replace these by only 1 if you want, but I highly recommend you to have things this way)
005: CookSkill
006: CookBook (yeah book, you will see why...)
Now let's start, base your first common event, CookStart on this one:
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookStart.jpg[/IMG]
Easy wasn't it? Now let's burn your brain cells.
But before, you need to know that the cooking will work based on dificulty. For example, dificulty 1 will be very easy to cook and will give the lowest amount of XP.
--------------------------------------------
Make the cooking common event, CookFish in this demo, based on this one:
Notes: The cooking action will be performed as a loop until there is no more of that particular food to cook. It's easy to add a way for the player to choose how much he wants to cook, but I decided not to do that in this demo. You must decide a dificulty level for each food, so when cooking it will use the right variable and give the player the correct amount of experience points.
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookFish.jpg[/IMG]http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookFish2.gif[/IMG]
Done? Now you just have to copy the first whole branch and paste it throughout the 3 common events, but changing the values at the same time, ofcourse.
...
...
...
Finally, you completed it. Cheer up, you have just completed the most sucky part! But, you still don't understand how it is done?
Well, Dificulty1 has the value of 10000, multiplied by the cooking skill (level 1) equals 10000. Then it is divided by 100 which equals 100. Then we get a random value from 1 to 100. If the division is bigger or equal to the random value we have a success, so it means we have a 100% success chance. If dificulty was 5000, divided by 100 equals 50 and we have a 50% chance of success, got it? GOOD!
--------------------------------------------
Now lets do the CookSkill common event.
Create a common event based on this one:
Notes: Here you will have to change the values in order to customize the dificulty of the Skill for your game. CookSkill is the Level, CookSkillXP is the current experience points and CookSkillXP2 is the current Skill's experience points cap, which means that when the CookSkillXP reaches the same value of CookSkillXP2, CookSkill is increased by 1.
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookSkill.jpg[/IMG]
Done? Now lets do the CookBook common event.
--------------------------------------------
Create a common event based on this one:
Notes: It's just a common event that will give the player some information about his cooking skill: known recipes, level and experience points. You can call this common event through a key or through an event placed on a map (a book on a table for example)
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookBook.jpg[/IMG]
Done. Let's move to the map events.
--------------------------------------------
Here is a screenshot of a kitchen, very simple but still a kitchen with a sailor in it for some reason.
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/kitchen.jpg[/IMG]
The sailor is the trainer and you will create this event based on the following:
Notes: This event has 2 pages. Make sure you check the triggering options. In this event you will set up the dificulty level variables. Here is how you will do it: dificulty level 1 value must be equal to 10000, level 2 equal to a value under 10000, since 10000 is the 100% success rate. Every value above will also be 100%.
Page 1:
!!There is an error. The Dificulty2 value is 20000, not 1000. Sorry about that!
http://i240.photobucket.com/albums/ff20 ... rPage1.jpg[/IMG]
http://i240.photobucket.com/albums/ff20 ... rPage1.jpg[/IMG]
Page 2:
http://i240.photobucket.com/albums/ff203/Peted2s/rmxp/CookTrainerPage2.jpg[/IMG]
Now the CookStart common event will be called in that cooking table.
The book has an event to call the CookBook common event.
--------------------------------------------
And that concludes it! (told you I am a bad teacher)
Further Reading
I appreciate your replies and comments, good or bad , so please, start writing! :p
If you find any flaws with the system, broken links/images or any other problem with this tutorial, posts.
I certainly won't explain you how to event, other people can help you with that, just not me.
This has been tested and it works, if it doesn't work for some reason, post a detailed description of the problem and I'll tell you what you have done wrong.
Don't post something stupid in this thread, please.
Get the demo *here*!
Credits:
Created entirely by me (based on World of Warcraft) and a crucial part by MarineMechx2 (thank you very much).
Thanks to:
The people who cared to help me at the General Support, thanks.
What MAY come from me in the future:
Advanced Gathering Skill
-Pete
Updates:
-Fixed the dificulty variable values. (forgot to change them before posting, go check them again..)
-Fixed the values again (if you were wondering why something was not right, try reading the dificulty values explanation again)