Announcement

Collapse
No announcement yet.

Tractor beam

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • replied
    Thanks for all the info! I'll have a good look at it as soon as I get the chance.

    Leave a comment:


  • replied
    I recommend studying the linkgun. When I made my MassManipulator
    of it it worked okay. The only problem with it is that you can't see the beam .

    Leave a comment:


  • replied
    http://www.pcgamemods.com/9151/

    works with karma and does no damage

    Leave a comment:


  • replied
    Actors have a variable called "Acceleration". This is used for example, state PlayerWalking( see playercontroller ). I think it's as simple as adjusting this acceleration value. It's a vector so u should add a vector pointing in the direction from the target towards you.

    U could use something like this:

    Code:
    function vector getTractorBeamForce(actor targetactor)
    {
             local vector Direction;
             local float Force;
             
             Direction = normal( /*U'r weapons location*/ - targetactor.location ); /* Creates a vector pointing in the same direction as from the target to your weapon. Normal() will give this vector a strength of one, meaning the same ammount as 1 unit in ur leveleditor */
    
             /* Calculate the force here, or use another function if that pleases u more. The force variable in this situation will be used to add a magnitude to the vector. The higher the forces, the higher the vector, the result: more pulling*/
    
             return Direction * Force; /* Direction is a vector of 1 unit strength, multiply this by Force and u will have a vector in the direction with the length of 'Force'. Meaning that if 'Force is 1024 the actor will eventually be pulled 1024 units to ur direction*/
    }
    
    function Pull(actor targetActor)
    {
             targetActor.Acceleration += getTractorBeamForce(targetActor); /* with this the Acceleration value is set, meaning the targetactor will Accelerate until it reaches this 'speed' or until acceleration is 0 */
    }

    nb: I didn't test it, it could be that I'm horribly wrong

    - Xcal

    Leave a comment:


  • replied
    I was thinking about the same effect for a vehicle. I was thinking of using (with permission of course), some code from chaosUT's gravity vortex. If nothing else, that code is a good place to look for ideas.

    Leave a comment:


  • started a topic Tractor beam

    Tractor beam

    I've been trying to create a cool tractor beam effect, but it's not as easy as I hoped it would be. Simply having a rapid fire weapon with reverse Momentum does not give a smooth tractor beam effect. I've been trying out pretty much every movement related setting I could find in Actor/Pawn/KarmaParams, but most of them don't produce any visible effect. I still have to try some karma stuff, but I'm much less experienced with that.

    I'm looking for the following advice:
    • Movement related settings known to work.
    • Karma related settings that might work.
    • Alternatives, such as perhaps attaching a "pulling" object to the target.
Working...
X