Jesse Freeman will teach you how to clean up the battle action so that the player or monster can correctly message when they miss an attack. You’ll also learn how to change the attack range values on the player and monster actors. Finally with modified combat starts for the player and monster you’ll learn when a perfect attack happens and message to the player that a critical hit has taken place.
- [Voiceover] Now let's take a look at how we…can clean up our attack battle action.…Two of the things we're gonna want to add…is the ability to let the monster…or the player miss their attack,…and also we want to display when a monster…or the player has a critical hit,…which happens when they attack…at the highest value of their attack range.…Let's go ahead and open up…our attack battle action.…In order for us to handle the miss,…let's take a look at splitting up…the two sentences we use to display our…attack battle action status.…
Above the second sentence where we…start with target2's name,…let's go ahead and add a condition…to test to see if attack value…is greater than zero.…If it is, that means we've had a successful hit.…If we've not made a hit,…let's add a new message to replace the one…where we show the target2's loss of HP.…Here we'll write an else condition…and inside of this, let's type sb.Append,…we'll use target1.name,…since this is our attacker,…and then sb.Append, and we'll add a string…starting with a space, and type out misses,…
- Preparing the user interface
- Creating game and message windows
- Building a battle window
- Adding a monster and action buttons
- Creating an actor class
- Adding player and monster attack actions
- Triggering battles from the map
- Ending a battle
- Cleaning up the battle and attack systems
- Rewarding the player
Skill Level Intermediate
1. Preparing the UI
2. Message Window
3. The Battle Window
4. Actor Classes
5. Battle Actions
6. Cleaning Up Combat
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.