ORK Framework Logo - RPG Editor for Unity
  • Features
  • Showcase
  • Guide
    • Documentation
    • Tutorials
    • API
  • ORK 2
    • Tutorials
    • Plugins
    • API
  • Support
  • Forum
  • Get ORK

2D RPG Quickstart

  • START 2D RPG Quickstart
  • 01 Initial Setup
  • 02 Player Setup
  • 03 Music & Scenes
  • 04 UI System Setup
  • 05 UI Boxes
  • 06 Flying Texts
  • 07 Status Values
  • 08 Status Effects
  • 09 First Abilities
  • 10 Fighter Setup
  • 11 First Enemies & Battle AI
  • 12 Battle System Setup
  • 13 Animating Battle Start and End
  • 14 Random Battles
  • 15 Animating Actions
  • 16 Player Battle HUD
  • 17 Elemental Attacks
  • 18 Animating More Actions
  • 19 Inventory & Loot
  • 20 Equipment
  • 21 Loot, Start Equipment & Viewers
  • 22 Magic Abilities
  • 23 Caster Setup
  • 24 More Enemies
  • 25 Start Menu & Save Games
  • 26 Menu Screens
  • 27 Interactions
  • 28 Item Collectors
  • END 2D RPG Quickstart

3D RPG Quickstart

  • START 3D RPG Quickstart
  • 01 Initial Setup
  • 02 Player Setup
  • 03 Music & Scenes
  • 04 UI System Setup
  • 05 UI Boxes
  • 06 Flying Texts
  • 07 Status Values
  • 08 Status Effects
  • 09 First Abilities
  • 10 Fighter Setup
  • 11 First Enemies & Battle AI
  • 12 Battle System Setup
  • 13 Animating Battle Start and End
  • 14 Random Battles
  • 15 Animating Actions
  • 16 Player Battle HUD
  • 17 Elemental Attacks
  • 18 Animating More Actions
  • 19 Inventory & Loot
  • 20 Equipment
  • 21 Loot, Start Equipment & Viewers
  • 22 Magic Abilities
  • 23 Caster Setup
  • 24 More Enemies
  • 25 Start Menu & Save Games
  • 26 Menu Screens
  • 27 Interactions
  • 28 Item Collectors
  • END 3D RPG Quickstart

Status System Setup

  • START Status System Setup
  • 01 Status Values
  • 02 Status Development
  • 03 Attack/Defence Modifiers
  • 04 Status Effects
  • 05 Formulas
  • 06 Ability & Item Types
  • 07 Abilities Part 1: Attacks
  • 08 Abilities Part 2: Support & Sabotage
  • 09 Abilities Part 3: Elemental Magic
  • 10 Items
  • 11 Equipment Part 1: Slots & Slot Set Templates
  • 12 Equipment Part 2: Weapons
  • 12.5 (Optional) Equipment Part 2.5: Weapons
  • 13 Equipment Part 3: Shields, Armor & Accessories
  • 13.5 (Optional) Equipment Part 3.5: Shields, Armor & Accessories
  • 14 Equipment Part 4: Available Equipment Templates
  • 15 Loot
  • 16 Battle AIs
  • 17 Combatants Part 1: General Settings
  • 18 Combatants Part 2: Players
  • 19 Combatants Part 3: Enemies
  • 20 Combatant Groups
  • END Status System Setup

3D RPG Playground

  • START 3D RPG Playground
  • 01 Player Setup
  • 02 Start Menu
  • 03 First Interaction
  • 04 Music
  • 05 Areas
  • 06 Collecting Items
  • 07 Displaying Equipment
  • 08 Combatant Prefabs, Icons & Portraits
  • 09 Combatant Animations
  • 10 Camera Positions
  • ANIM 01 Battle Start/End Schematics
  • ANIM 02 Use, Cast & Camera
  • ANIM 03 Abilities & Items
  • ANIM 04 Physical Attacks
  • ANIM 05 Special Actions
  • BATTLE 01 Battle Menu
  • BATTLE 02 Prepare for Battle
  • TURN 01 Turn Based Setup
  • TURN 02 Turn Order HUD
  • ATB 01 Active Time Setup
  • ATB 02 Cast Times
  • ATB 03 Timebar HUD
  • BATTLE 03 The First Battle
  • BATTLE 04 Hunting Move AI
  • BATTLE 05 Spawning Combatants
  • 11 Save Games
  • MENU 01 UI Boxes
  • MENU 02 Template HUDs
  • MENU 03 Overview Menu
  • MENU 04 Menu Screens
  • 12 Shop
  • BATTLE 06 Random Battles
  • DUNGEON 01 Enter the Dungeon
  • DUNGEON 02 The Trapdoor
  • DUNGEON 03 Enemies on Level 1 & 2
  • DUNGEON 04 Traps on Level 3
  • DUNGEON 05 Going Deeper
  • 13 Bestiary (+MENU+ANIM)
  • QUEST 01 Hunting Quests (+MENU)
  • QUEST 02 Guard NPC
  • QUEST 03 Forest Ruin Cheese
  • QUEST 04 Witch NPC with Cheese
  • QUEST 05 Quest Mark HUDs
  • 14 Research Trees (+MENU)
  • CRAFT 01 Crafting Materials
  • CRAFT 02 Crafting Recipes
  • CRAFT 03 Crafting Menu
  • CRAFT 04 Crafting Proficiency & Critical Crafting
  • CRAFT 05 Materials Loot
  • 15 Changing Choice Dialogue
  • 16 Follow Me!
  • BATTLE 07 Sequence Loot Dialogue

3D Action RPG

  • START 3D Action RPG
  • 01 Status System Setup
  • 02 Player Setup
  • 03 Player Weapon
  • 04 Player Attacks
  • 05 Enemy: Chomper
  • 06 Chomper Attack
  • 07 Hit & Death
  • 08 HUDs
  • 09 Rolling on the Floor
  • 10 Enemy: Spitter
  • 11 Spit Attack
  • 12 Potion
  • 13 Grenade
  • 14 Item HUD
  • 15 Enemy: Grenadier
  • 16 Grenadier Melee Attacks
  • 17 Grenadier Flamethrower
  • 18 Item Drops
  • END 3D Action RPG

2D Grid Battle RPG

  • START 2D Grid Battle RPG
  • 01 Player Setup
  • 02 Prefab & Music Setup
  • 03 Randomizing Combatants
  • 04 UI Setup
  • 05 Battle Start, End & Phase Schematics
  • 06 Battle System Setup
  • 07 Battle Grid Setup
  • 08 Grid Move
  • 09 Forest Battle Grid
  • 10 Battle AI
  • 11 Ability Ranges
  • 12 Death & Use Schematics
  • 13 Attack Schematic
  • 14 Shoot Schematics
  • 15 Battle Selection Interaction
  • END 2D Grid Battle RPG

Schematics

  • Simple Start Schematic
  • Battle Start Schematic
  • Battle End Schematic
  • Moving to Target and Back
  • Animating a Base Attack
  • Animating a Magic Ability
  • Grid Movement
  • Open and Close UI Animations
  • Flying Text Mover

UI Setups

  • Unity UI: Initial Setup
  • Unity UI: TextMesh Pro Setup
  • Unity UI: UI Box
  • Unity UI: Flying Text
  • Unity UI: Dragging Notification
  • Unity UI: Canvas with Screen Space Camera
  • Unity UI: Interaction HUD
  • Unity UI: Simple Player HUD
  • Unity UI: Quest HUD
  • Unity UI: Shortcuts HUD
  • Unity UI: Currency HUD
  • Unity UI: Tooltip HUD
  • Unity UI: Control HUD
  • Unity UI: Attack Modifiers
  • Unity UI: Defence Modifiers

Gameplay Bits

  • Combining Input Origins
  • Combining Status Value Flying Texts
  • Fun With Flying Text
  • HUD Effects With Conditional Schematics
  • Inventory Containers
  • Multi Interaction Controllers
  • World Space HUD
  • World Space Dialogue
  • Home
  • Guide
  • Tutorials
  • 3D Action RPG
  • 13 Grenade

13 Grenade

Table of Contents
  • Cursor Pulse Schematic
    • Settings
    • Change Scale
    • Change Scale
    • Restart Schematic
  • Grenade Throw Schematic
    • Settings
      • Prefabs
    • Rotate To
    • Play Sound
    • Combatant Animation
    • Consume Costs
    • Spawn Prefab
    • Wait
    • Activate Damage Dealer
    • Rigidbody Change Velocity
    • Start Tagged Machine
    • Wait
  • Grenade Boom Schematic
    • Wait
    • Enable Component
    • Wait
    • Activate Object
    • Destroy Object
    • Play Sound
    • Mount Object
    • Activate Object
    • Wait
  • Battle Range Template
    • Range Settings > Maximum Range
  • Grenade Item
    • Use Settings > Battle Settings > Reuse Settings
    • Target Selection Settings
      • Raycast Settings
      • Use Range Settings
    • Target Settings > Target Changes > Target Change 0 > Status Change 0
    • Battle Animation > Battle Animation 0
    • Battle Animation > Damage Dealer Settings
  • Updating the Control Map
    • Control Key 3
      • Input Settings
      • Action Settings
      • Conditions
  • Updating Ellen
    • Inventory & Equipment > Start Inventory
  • Battle Menu
  • Save Changes
  • Cursor Prefab Setup
    • Auto Machine
      • Start Settings
      • Machine Execution Settings
  • Grenade Prefab Setup
    • Add Tagged Machine
      • Start Settings
      • Machine Execution Settings
    • Point Of Interest
    • Add Damage Dealer
      • Activation Settings
  • Testing

In this tutorial we’ll set up a throwable grenades.

The grenade is thrown to a position the player selects and explodes after some time. The time will stand still while selecting the position to throw to, and we’ll display a selection cursor following the mouse (in the game world).

We’ll set up:

  • schematic to pulse the cursor (scaling it up/down)
  • schematic to throw the grenade
  • schematic to explode the grenade
  • grenade item
  • update the control map
  • add grenades to the player’s start inventory
  • set up the grenade and cursor prefabs

Let’s get to it.

Cursor Pulse Schematic #

This one will be pretty simple – it’ll scale the cursor up and down and restart, until the game object is destroyed again (which stop’s it’s Auto Machine that uses the schematic).

Navigate to Schematics and start working on a new schematic.

Settings #

We’ll disable using Unity and Makinom timescales – i.e. the schematic will perform in unscaled time.

This is needed, since the cursor is displayed during timescale being set to 0.

  • Unity Time Scale
    Disable this setting.
  • Makinom Time Scale
    Disable this setting.

Change Scale #

Add Node > Movement > Movement > Change Scale

We’ll use this node to scale the game object over time.

The cursor’s game object has a scale of 5 (on all axes) when it’s spawned, we’ll increase the scale to 5.5.

  • Object (Scaling Object)
    Select Machine Object.
  • Vector3 Type (Scale)
    Select Value > Value.
  • Value
    Set to X=5.5, Y=5.5, Z=5.5.
  • Fade Scale
    Enable this setting.
  • Time
    Select Value > Value.
    Set the value to 0.5.
  • Wait
    Enable this setting.
  • Interpolation
    Selec Quadratic > Quadratic In + Out.

Change Scale #

Duplicate the Change Scale node. We’ll scale back to 5.

  • Value
    Set to X=5, Y=5, Z=5.

Restart Schematic #

Add Node > Machine > Restart Schematic

This node will restart the schematic in the next frame. No further settings needed.

And that’s it for the schematic. Click on Save Schematic to save it, e.g. as CursorPulse.

Grenade Throw Schematic #

The position we throw the grenade to is selected using a raycast during the player’s target selection – this is availabe as the Starting Object of the schematic (it’s an empty game object that’ll be destroyed after the item action ended).

Our grenade throw will be similar to the Spit Attack we already set up, i.e. we’ll rotate to the target, throw the thing and activate it … more or less.

Create a new schematic.

Settings #

We’ll block the player controls.

  • Block Player Control
    Enable this setting.

Prefabs #

We also add the grenade prefab.

Click on Add Prefab Resource.

  • Prefab
    Select the Grenade prefab.
    You can find it in Assets/Tutorial Assets/Prefabs/Weapons/.

Rotate To #

Add Node > Movement > Rotation > Rotate To

We’ll do a quick rotation to the Starting Object.

  • Object (Rotating Object)
    Select Machine Object.
  • Rotate Component
    Select Transform.
  • Lock Rotation
    Enable X and Z.
  • Rotation Target
    Select Game Object.
  • Object
    Select Starting Object.
  • Fade Rotation
    Enable this setting.
  • Time
    Select Value > Value.
    Set the value to 0.1.
  • Wait
    Enable this setting.
  • Interpolation
    Select Linear.

Play Sound #

Add Node > Audio > Audio > Play Sound

  • Object (Play On)
    Select Machine Object.
  • Audio Clip Asset
    Select swoosh01.
  • Play One Shot
    Enable this setting.
  • Set Pitch
    Enable this setting.
  • Random Pitch
    Enable this setting.
  • Pitch
    Set to 0.8.
  • Pitch 2
    Set to 1.2.

Combatant Animation #

Add Node > Animation > Combatant > Combatant Animation

We’ll play the combatant’s attack animation (looks like a throw without the staff).

  • Object
    Select Machine Object.
  • Animation Type
    Select Attack.
  • Wait
    Enable this setting.
  • Normalized Time (Wait)
    Set to 0.08.
  • Store Duration
    Enable this setting.
  • Normalized Time (Store Duration)
    Set to 0.9.
  • Variable Key
    Set to wait.
  • Variable Origin
    Select Local.

Consume Costs #

Add Node > Battle > Action > Consume Costs

This node will consume the action’s use costs, i.e. remove 1 grenade from the user’s inventory.

No further settings.

Spawn Prefab #

Add Node > Game Object > Prefab > Spawn Prefab

We’ll now spawn the grenade prefab.

You could also use the position of the combatant’s hand (or any other child object) if you want, but roughly positioning it with an offset is enough.

  • Prefab
    Select Prefab 0.
  • Target Type
    Select Object.
  • Object (Target Object)
    Select Machine Object.
  • Local Space
    Enable this setting.
  • Offset
    Set to X=0, Y=1, Z=0.5.
  • Use Rotation
    Enable this setting.

Wait #

Add Node > Base > Wait

We’ll wait for a frame (0 seconds) to give the prefab time to spawn.

  • Time
    Select Value > Value.
    Set the value to 0.

Activate Damage Dealer #

Add Node > Battle > Action Outcome > Activate Damage Dealer

We’ll now activate the damage dealer on the spawned prefab (via the ability’s activation tags, which we’ll set up after this).

The damage dealer is placed on a disabled game object of the grenade prefab, but we can still activate it. We’ll later enable the game object when it’s time to do damage.

  • Object (Activate On)
    Select Prefab 0.
  • Activate
    Enable this setting.
  • Use Action Tags
    Enable this setting.
  • Set Action
    Enable this setting.

Rigidbody Change Velocity #

Add Node > Game Object > Rigidbody > Rigidbody Change Velocity

Instead of adding a force, we’ll this time set the velocity that’s calculated to reach the position we want to hit.

This could be quite complicated, but luckily Makinom comes with the Shot Velocity Vector3 value selection to handle that for us with a few simple settings.

  • Object (Rigidbody Object)
    Select Prefab 0.
  • Vector3 Type
    Select Physics > Shot Velocity.
  • Shot Type
    Select Random.
    This’ll create a random velocity between highest and lowest shot arc.
  • Speed
    Select Value > Value.
    Set the value to 8.
    This matches the grenade throws maximum use range (which will be 8 as well).
  • Vector3 Type (Origin Position)
    Select Game Object > Game Object.
  • Object
    Select Prefab 0.
    The shot is calculated from the spawned prefab’s position.
  • Vector3 Type (Target Position)
    Select Game Object > Game Object.
  • Object
    Select Starting Object.
    The shot is calculated to the position that was selected.

Start Tagged Machine #

Add Node > Machine > Start Tagged Machine

We’ll now start a tagged machine on the grenade (spawned prefab) that’ll handle wait time and explosion for us without blocking the user any longer.

  • Wait
    Disable this setting.
    We don’t need to wait for the machines to finish.
  • Object (Machine Object)
    Select Prefab 0.
  • Use Same Object
    Enable this setting.
    The prefab will also be used as starting object of the tagged machine.

Click on Add Tag to add a starting tag.

  • Tag
    Set to grenade.

Wait #

Add Node > Base > Wait

We’ll now wait for the stored duration

  • Time
    Select Variable > Float Variable.
  • Variable Key
    Set to wait.
  • Variable Origin
    Select Local.

And that’s it for the schematic. Click on Save Schematic to save it, e.g. as GrenadeThrow.

Grenade Boom Schematic #

And the last schematic, handling the grenade’s explosion. It’ll be started by the tagged machine on the grenade.

We’ll mainly use activation and destruction of game objects and components this time. The grenade’s prefab has already everything set up, we just need to use it:

  • enable it’s collider (after a short wait to not collide with the thrower)
  • enable the explosion particle effect, unparent it and destroy it after time
  • enable the damage dealer’s game object

Create a new schematic.

Wait #

Add Node > Base > Wait

We’ll wait for a short time to give the grenade enough time to leave the thrower’s game object.

  • Time
    Select Value > Value.
    Set the value to 0.2.

Enable Component #

Add Node > Game Object > Component > Enable Component

We’ll enable the Sphere Collider component on the grenade (i.e. the Machine Object).

  • Enable/Disable
    Enable this setting.
  • Component Name
    Set to SphereCollider.
  • Object
    Select Machine Object.

Wait #

Add Node > Base > Wait

And we wait for another 3.3 seconds – i.e. the grenade will explode after 3.5 seconds.

  • Time
    Select Value > Value.
    Set the value to 3.3.

Activate Object #

Add Node > Game Object > Game Object > Activate Object

We’ll now activate the BigExplosion child object, which is the explosion particle effect.

Activating (i.e. enabling) the game object will start it’s particle system and play the effect.

  • Set Active
    Enable this setting.
  • Object
    Select Machine Object.
  • Child Object
    Set to BigExplosion.

Destroy Object #

Add Node > Game Object > Game Object > Destroy Object

We’ll now mark the BigExplosion child object to be destroyed after 3 seconds.

We do this because we’ll also unmount the game object from the grenade next. The explosion should be visible longer than the grenade is alive (it’ll be destroyed shortly after doing damage).

  • Object
    Select Machine Object.
  • Child Object
    Set to BigExplosion.
  • Destroy After Time
    Enable this setting.
  • Time
    Set to Value > Value.
    Set the value to 3.

Play Sound #

Add Node > Audio > Audio > Play Sound

We play an explosion sound on the explosion effect.

  • Object (Play On)
    Select Machine Object.
  • Child Object
    Set to BigExplosion.
  • Audio Clip Asset
    Select ExplosionMetal.
  • Play One Shot
    Enable this setting.
  • Set Pitch
    Enable this setting.
  • Random Pitch
    Enable this setting.
  • Pitch
    Set to 0.8.
  • Pitch 2
    Set to 1.2.

Mount Object #

Add Node > Game Object > Game Object > Mount Object

And now we’ll unmount the explosion from the grenade.

  • Mount
    Disable this setting.
  • Object
    Select Machine Object.
  • Child Object
    Set to BigExplosion.

Activate Object #

Duplicate the previous Activate Object node, this time we activate the DamageDealer child object of the grenade.

The Damage Dealer component on it is already activated (from the throwing schematic) and will do damage after we activate it.

  • Child Object
    Set to DamageDealer.

Wait #

Add Node > Base > Wait

And finally, we wait another short time.

The tagged machine we’ll set up on the grenade will automatically destroy the game object when it finishes, so this wait time is used to give the damage dealer enough time to do damage.

  • Time
    Select Value > Value.
    Set the value to 0.1.

And that’s it for the schematic. Click on Save Schematic to save it, e.g. as GrenadeBoom.

Battle Range Template #

We’ll add a new battle range template for the grenade, which as a use range of 8.

Navigate to Templates > Battle Range Templates and add a new template.

  • Name
    Set Range 8.

Range Settings > Maximum Range #

  • Maximum Range
    Enable this setting.
  • Range
    Select Value > Value.
    Set the value to 8.

Grenade Item #

We can build upon the potion we set up in the last tutorial. The grenade will deal 50 damage to HP.

Navigate to Inventory > Items and copy the Potion item.

  • Name
    Set to Grenade.
  • Sprite (Icon)
    Select icons_267.

Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.

Use Settings > Battle Settings > Reuse Settings #

We’ll change the reuse time to 5 seconds

  • Reuse After
    Select Value > Value.
    Set the value to 5.

Target Selection Settings #

The grenade should damage all – and we’ll use a raycast (and cursor) to select a target position to throw to.

  • Target Type
    Select All.
  • Target Range
    Select None.
    This is needed to have no regular target selection and use raycast targeting instead.

Raycast Settings #

  • Use Target Raycast
    Enable this setting.
  • Layer Mask
    Select only the Default layer.
    First select Nothing, then the Default layer.
  • Clamp To Use Range
    Enable this setting.
    The raycasted position will stick to the use range instead of exceeding it.
  • Ray Origin
    Select Screen.
    The raycast will come from the screen (otherwise it can also come from the user’s game object).

We’ll use the Mouse/Touch Controls to select a position by clicking.

  • Input Type
    Select Both.
  • Mouse Button
    Set to 0.
    This uses the left mouse button.

We’ll use a Cursor Object to mark the position in the scene.

  • Use Cursor
    Enable this setting.
  • Prefab
    Select GrenadeCursor.

Use Range Settings #

  • Own Use Range
    Enable this setting.

Click on Add Range.

  • Range Type
    Select Template.
  • Template
    Select Range 8.

Target Settings > Target Changes > Target Change 0 > Status Change 0 #

Instead of adding 50, we’ll subtract 50 from HP.

  • Operator
    Select Sub.

Battle Animation > Battle Animation 0 #

  • Schematic Asset
    Select GrenadeThrow.

Battle Animation > Damage Dealer Settings #

Click on Add Tag.

  • Tag
    Set to boom.

This is the same activation tag we’ll used on the grenade’s prefab.

Click on Add Battle Animation. We’ll use the schematic we’ve set up to animate the damage dealer hit.

  • Schematic Asset
    Select DamageDealerHit.

Updating the Control Map #

We’ll now update the control map.

Navigate to Base/Control > Control Maps and select the Default control map.

Control Key 3 #

Click on Add Control Key.

Input Settings #

  • Input Key
    Select Grenade.

Action Settings #

  • Type
    Select Action.
  • Action
    Select Item.
  • Item
    Select Grenade.
  • 2nd Call Cancels Targeting
    Enable this setting.
    This lets us cancel the grenade target selection by pressing the grenade key again.

Conditions #

  • During Target Selection
    Enable this setting.
    Otherwise we couldn’t cancel the target selection.

Updating Ellen #

We add a few grenades to Ellen’s start inventory.

Navigate to Combatants > Combatants and select Ellen.

Inventory & Equipment > Start Inventory #

Click on Add Item.

  • Type
    Select Item.
  • Item
    Select Grenade.
  • Quantity
    Select Value > Value.
    Set the value to 20.

Battle Menu #

While we don’t use the battle menu, it’s still active in the background during things like the target selection – and also during our raycast targeting.

We make use of that and set the time scale to 0 while the battle menu is displayed.

Navigate to UI > Battle Menus and select the Default battle menu (this is already set up as the default battle menu in Battles > Battle System > General Settings).

  • Change Time Scale
    Enable this setting.
  • Time Scale
    Set to 0.

Save Changes #

That’s it for the editor setup.

Don’t forget to save your changes by clicking on Save Settings at the bottom of the editor.

Cursor Prefab Setup #

We still need to set up our prefabs, we’ll start with the Grenade Cursor.

Open the GrenadeCursor prefab for editing – you can find it in Assets/Tutorial Assets/Prefabs/.

Auto Machine #

Add an Auto Machine component using the component menu.

Start Settings #

  • Enable
    Enable this setting.
    The machine will start when the game object is enabled.

Machine Execution Settings #

  • Schematic Asset
    Select the CursorPulse schematic.

That’s it for the cursor prefab – save the changes.

Grenade Prefab Setup #

Open the Grenade prefab for editing – you can find it in Assets/Tutorial Assets/Prefabs/Weapons/.

Add Tagged Machine #

Add a Tagged Machine component to the prefab’s root using the component menu.

Start Settings #

Click on Add Starting Tag.

  • Tag
    Set to grenade.

Machine Execution Settings #

  • Schematic Asset
    Select the GrenadeBoom schematic.
  • Machine End Action
    Select Destroy.
    This’ll automatically destroy the grenade after the schematic finished.

Point Of Interest #

Add a Point Of Interest component to the prefab’s root using the component menu.

This component will be detected by the move AI and let the enemies move toward it – i.e. we’ll lure them to the grenade to get blown up!

  • Schematic Asset
    Select the IdleWait schematic.
    This is the same schematic we used for the move AI’s idle behaviour.
    The combatant will use the schematic when reaching the PoI.
  • Wait
    Enable this setting.
    The combatant will wait for the schematic to finish.

Add Damage Dealer #

Add a Damage Dealer component to the disabled DamageDealer child object of the prefab using the component menu.

  • Start Type
    Select Trigger Enter.
  • One Time Damage
    Enable this setting.

Activation Settings #

If you remember, we used the activate tag boom in the grenade item, so we need to use that here as well.

  • Field
    Enable this setting.
  • All Battle Systems
    Enable this setting.

Click on Add Activation Tag.

  • Activation Tag
    Set to boom.

And that’s it for the grenade prefab’s setup – save the changes.

Testing #

Hit play and throw some grenades.

Remember, the grenade key is E.

Selecting a position to throw to works – stops the time and the cursor pulsates

And enemies (that don’t have a target) are lured to it through the Point Of Interest component.

And killed – great!

 

Next, we’ll set up a HUD to show our available items.

Share This Article :
  • Facebook
  • Twitter
  • LinkedIn
  • Pinterest
Updated on May 13, 2022
Table of Contents
  • Cursor Pulse Schematic
    • Settings
    • Change Scale
    • Change Scale
    • Restart Schematic
  • Grenade Throw Schematic
    • Settings
      • Prefabs
    • Rotate To
    • Play Sound
    • Combatant Animation
    • Consume Costs
    • Spawn Prefab
    • Wait
    • Activate Damage Dealer
    • Rigidbody Change Velocity
    • Start Tagged Machine
    • Wait
  • Grenade Boom Schematic
    • Wait
    • Enable Component
    • Wait
    • Activate Object
    • Destroy Object
    • Play Sound
    • Mount Object
    • Activate Object
    • Wait
  • Battle Range Template
    • Range Settings > Maximum Range
  • Grenade Item
    • Use Settings > Battle Settings > Reuse Settings
    • Target Selection Settings
      • Raycast Settings
      • Use Range Settings
    • Target Settings > Target Changes > Target Change 0 > Status Change 0
    • Battle Animation > Battle Animation 0
    • Battle Animation > Damage Dealer Settings
  • Updating the Control Map
    • Control Key 3
      • Input Settings
      • Action Settings
      • Conditions
  • Updating Ellen
    • Inventory & Equipment > Start Inventory
  • Battle Menu
  • Save Changes
  • Cursor Prefab Setup
    • Auto Machine
      • Start Settings
      • Machine Execution Settings
  • Grenade Prefab Setup
    • Add Tagged Machine
      • Start Settings
      • Machine Execution Settings
    • Point Of Interest
    • Add Damage Dealer
      • Activation Settings
  • Testing
Sitemap
  • Features
  • Showcase
  • Guide
    • Documentation
    • Tutorials
    • API
  • ORK 2 Hub
    • Tutorials
    • Plugins
    • API
  • Support
  • Forum
  • Get ORK
  • Contact
  • Blog
  • Makinom
  • gamingislove.com
Categories
  • News (60)
  • ORK 2 (137)
    • Tutorial (137)
      • Game tutorial (50)
      • Gameplay (32)
      • How-to (55)
  • Release (130)
Search

© 2015 Gaming is Love e.U.

Disclosure: This site may contain affiliate links, which means I may receive a commission if you click a link and purchase something that I have recommended. While clicking these links won’t cost you any money, they will help me fund my development projects while recommending great assets!