The Game Modding Community - Since 2001

How to make a model Killable/Breakable

A Tutorial for GoldSrc Engine

This tutorial teaches how to make a model vanish when you shoot at it, like chickens of Italy.

If you are reading this tutorial, I am considering that you already have the basic knowledge of how triggering of entity works.

Entities we're gonna use:-

  • Cycler_sprite:- Used for placing a 3D model in the map.
  • Env_render:- Used for changing the render properties for the target.
  • func_breakable:- Used for making a brush/block breakable, can be used to initiate the trigger when you shoot at it.
  • enc_shooter:- Used for shooting Gibs (pieces of something, here feathers) in the air.
  • ambient_generic:- Used for playing a sound.
  • trigger_multiple:- Used for triggering an event when you touch this brush based entity.

Procedure

  1. Place the cycler_sprite entity (for placing the chicken model) and name it as chicken.
  2. Place 2 env_render entities nearby your cycle_sprite.
  3. In the properties of one of the env_render entity, put
    Name - kill,
    target - chicken,
    render mode - additive,
    fx amount - 0. (now when we trigger "kill", it changes the render property of its target "chicken" and make it invisible).
  4. In the property of other env_render, put
    Name - respawn,
    target - chicken,
    render mode - normal,
    fx amount - 255. (when "respawn is triggered, it changes the render property of its target "chicken" and make it visible).
  5. Make a func_breakable brush entity (size and shape similar to your model) right over the cycler_sprite, in its properties, put
    target on break - kill (on breaking this, it triggers "kill" env_render and makes the model disappear),
    material type - flesh,
    gib direction - relative to attack,
    render mode - texture (some light)(this makes the func_breakable invisible and only model appears).
  6. Put a env_shooter entity above the cycler_sprite, name it "kill" (so that it gets triggered when u break/shoot at the func_breakable), choose feather model in "model" field. (on being triggered it shoots feathers in the air.)
  7. Put ambient_generic somewhere near, with chickens voice, name it "kill" so that it gets triggered when u shoot the func_breakable.
  8. Put a brush in a place away from this place (probably where the players spawn), such that a player passes through this brush while walking around. Tie this to trigger_multiple. put
    Target - "respawn" in the property. (when the player passes through this, it triggers "respawn" evn_render and the chicken appears again.)




What is happening here



  • When you shoot at the model in the map, you are actually shooting at the invisible func_breakable that is coinciding your model. This func_breakable calls all the entities named "kill".
  • The env_render named "kill" on being called, targets the "chicken" (cycler_sprite) and changes its Render Mode to Additive and FXamount to 0, thus making it invisible.
    Simultaneously, Ambient_generic and env_shooter which are also named "kill" play the sound and shoot the feather gibs in the air.
  • When the player spawns and passes through the trigger_multiple, env_render "respawn" is triggered and it changes the Render Mode and Fxamount of cyclcer_sprite back to normal and 255 respectively and thus makes it appear again.
  • func_breakable gets reset as the round starts.
you can use the same way to make breakable wine glasses, bottles etc.

Example Prefab

That's all for this time.
Hope to see some chickens soon.
Happy Mapping.

Promotional Content

Posts

  • 4y
    Glock18 avatar
    Glock18 username pic Joined 4y ago
    Offline
    1,977 points Ranked 2523rd
    26 medals 1 legendary 3 rare
    • Returned 5000 times Medal icon
    • Returned 1000 times Medal icon
    • Reached 50 subscribers Medal icon
    • Submitted 20 Maps Medal icon
    • Winter Worlds Mapping Contest Entrant Medal icon
    • Journey to the Center of the Earth Entrant Medal icon
    Very clear tutorial. I wouldn't have understood it entirely, but the prefab set-up just topped it off -- 10/10.

    10

    Need a mapper? PM me!
  • 4y
    Ring-A-Ding Rampage avatar
    Ring-A-Ding Rampage username pic Joined 7y ago
    In Continuum
    2,500 points Ranked 1975th
    74 medals 9 legendary 20 rare
    • Submitted 60 Sprites Medal icon
    • Thanked 500 submitters Medal icon
    • 15+ Entries! GameBanana’s Christmas Giveaway 2015 Medal icon
    • Submitted 100 Skins Medal icon
    • Reached 100 subscribers Medal icon
    • 15+ Entries! GameBanana’s Christmas Giveaway 2016 Medal icon
    Ring-A-Ding Rampage avatar
    Ring-A-Ding Rampage
    (づ。◕‿‿◕。)づ
    > **Posted by Akshit** > > **Posted by KaranMohadkar** > > > **Improvements:** > > > > - Add Source file as an example, so people can download , thats the best way to learn ! > > will do that as soon as i'm back home, also a flowchart diagram is coming up. This was made in a hurry. Wow, flowcharts! :D.

    10

    I'mma deck you in the schnoz. avatar
    Mantra
    I'mma deck you in the schnoz.
  • 4y
    Akshit Saklani avatar
    Akshit Saklani Joined 6y ago
    Offline
    24,538 points Ranked 183rd
    48 medals 3 legendary 8 rare
    • 15+ Entries! GameBanana’s Christmas Giveaway 2015 Medal icon
    • 15+ Entries! GameBanana’s Christmas Giveaway 2016 Medal icon
    • 15+ Entries! GameBanana’s Christmas Giveaway 2017 Medal icon
    • GameBanana’s Christmas Giveaway 2015 Day Seven Winner! Medal icon
    • GameBanana’s Christmas Giveaway 2015 Day Thirteen Winner! Medal icon
    • 25 posts awarded Exemplary Feedback Medal icon
    > **Posted by KaranMohadkar** > **Improvements:** > > - Add Source file as an example, so people can download , thats the best way to learn ! will do that as soon as i'm back home, also a flowchart diagram is coming up. This was made in a hurry.
    Fall 7 times, stand up 8! avatar
    Mantra
    Fall 7 times, stand up 8!
  • 4y
    KaranMohadkar avatar
    KaranMohadkar Joined 6y ago
    Offline
    9,112 points Ranked 508th
    17 medals 1 rare
    • Returned 1000 times Medal icon
    • 1-5 Entries! GameBanana’s Christmas Giveaway 2014 Medal icon
    • Reached 1,000 Points Medal icon
    • Reached 2,500 Points Medal icon
    • 1 post awarded Exemplary Feedback Medal icon
    • One month a member Medal icon
    **Improvements:** - Add Source file as an example, so people can download , thats the best way to learn !

    9

    Trying To Learn Mapping :P

Embed

Share banner
Image URL:
HTML embed code:
BB embed code:
Markdown embed code:

Credits

Original Authors
Akshit Saklani
Akshit Saklani Joined 6y ago
Offline
24,538 points Ranked 183rd
48 medals 3 legendary 8 rare
  • 15+ Entries! GameBanana’s Christmas Giveaway 2015 Medal icon
  • 15+ Entries! GameBanana’s Christmas Giveaway 2016 Medal icon
  • 15+ Entries! GameBanana’s Christmas Giveaway 2017 Medal icon
  • GameBanana’s Christmas Giveaway 2015 Day Seven Winner! Medal icon
  • GameBanana’s Christmas Giveaway 2015 Day Thirteen Winner! Medal icon
  • 25 posts awarded Exemplary Feedback Medal icon
Author

Submitter

Akshit Saklani avatar
Akshit Saklani Joined 6y ago
Offline
24,538 points Ranked 183rd
48 medals 3 legendary 8 rare
  • 15+ Entries! GameBanana’s Christmas Giveaway 2015 Medal icon
  • 15+ Entries! GameBanana’s Christmas Giveaway 2016 Medal icon
  • 15+ Entries! GameBanana’s Christmas Giveaway 2017 Medal icon
  • GameBanana’s Christmas Giveaway 2015 Day Seven Winner! Medal icon
  • GameBanana’s Christmas Giveaway 2015 Day Thirteen Winner! Medal icon
  • 25 posts awarded Exemplary Feedback Medal icon

Akshit Saklani
Creator
Sign up to access this!
Sign up to access this!
Sign up to access this!
Sign up to access this!

Category

Details

Difficulty Level
Intermediate Difficulty

Share

  • Share on Reddit
  • Share on Twitter
  • Share on Facebook
  • Share on Google+

Stats

  • 4,031 Views
  • 4 Posts
  • 4y Submitted
  • 2y Modified

Scores

87 bScore
9.8 Rating

7 voters

Sign up to access this!

Attention Gamer! Mascot

GameBanana is one of the oldest mod sites on the net. Sign up and maximize your browsing experience.

  • Subscribe: Get notified of new submissions like this.
  • Say Thanks: Show your appreciation - send modders points.
  • Post: Give modders your thoughts on their work.
  • Vote: Help your favorite modders win monthly awards.
  • Rate: Rate mods and help them stand out.
  • Flag: Alert moderators and warn members of problems with mods.
  • Watch: Get notified when mods are updated.

Join the community! Sign up now!

Already a Bananite? Login

WiPs by Submitter

bcp.crwdcntrl.net tracking pixel