• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

How to make units fly away?

Status
Not open for further replies.
Level 9
Joined
Oct 11, 2009
Messages
477
Is there a way on how to make units fly away? For example, a bomb explodes on Point X, units within 1000 of Point X flies away at a height of 1000 and a rate of 300 and then returns back to ground even if they are already corpses with a rate of 450. Im not sure if jumping system will solve this.

Thanks for the helper and +rep!!!:grin:
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
A jumping system can do that for you, except increasing/decreasing speeds will be the same.

When the bomb explodes, pick all units nearby, and save the values required by the jumping system for each unit and add the units to the "jump" unit group or what ever is required to execute the "jump".

Remember to use angle from the bomb to the unit.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
There are a few types of systems that would be able to manage this sort of thing:
  • Physics Engine
  • "Jump" System
  • Projectile System

A physics engine would obviously be ideal for this type of thing, since you would be able to create a realistic motion path without much effort. A jump system could also be used to handle this, and if you're using GUI I would recommend this (if you don't already need a physics engine anyways). It is simple, and relatively easy to control with GUI.

If you use vJass then I would direct you to my projectiles library, which could handle this sort of thing pretty well.

***Wow it takes me a long time to post.
 
Status
Not open for further replies.
Top