Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Unreal Engine Game Development Blueprints

You're reading from   Unreal Engine Game Development Blueprints Discover all the secrets of Unreal Engine and create seven fully functional games with the help of step-by-step instructions

Arrow left icon
Product type Paperback
Published in Dec 2015
Publisher Packt
ISBN-13 9781784397777
Length 352 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Nicola Valcasara Nicola Valcasara
Author Profile Icon Nicola Valcasara
Nicola Valcasara
Arrow right icon
View More author details
Toc

Killer objects


Let's add some dangerous objects for the player. The first one is an easier version of the KillZ volume. Create a new Blueprint extending an Actor and call it KillVolume. Add a box collision on the Viewport and extend its onActorBeginOverlap method with the KillPlayer function we created earlier as single node. You can understand the advantages of the function libraries now:

Duplicate this Blueprint and call it RollingBall. Change the collision box with a sphere and add a Sphere mesh with enabled physic. Those dangerous balls will be thrown down a hill ready to kill the player. Don't forget to choose OverlapOnlyPawn from the Collision Presets dropdown, unless you want that you player is killed by unwanted collisions:

Duplicate this item and call it Bullet. Make it smaller, remove the physic simulation, and add a Projectile component. Use the same settings we used in the previous chapters: Autoactivate, Initial Speed, max force of 2000, and 0 gravity. On the Event Graph, set...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image