1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Hey Guest, is it this your first time on the forums?

    Visit the Beginner's Box

    Introduce yourself, read some of the ins and outs of the community, access to useful links and information.

    Dismiss Notice

[Solved]Taking control over other player

Discussion in 'Modding Help' started by LightTab2, Jul 13, 2014.

  1. LightTab2

    LightTab2 Drill Rusher
    1. Zen Laboratories

    Messages:
    83
    Can somebody test it(need atleast 2 players)?
    Code:
    f32 onPlayerTakeDamage( CRules@ this, CPlayer@ victim, CPlayer@ attacker, f32 DamageScale )
    {
    CBlob@ ghost = attacker.getBlob();
    CBlob@ blob = victim.getBlob();
    if (blob.getName() == "knight" || blob.getName() == "archer" || blob.getName() == builder)
    {
    ghost.Die();
    blob.UnplugPlayer();
    blob.PlugPlayer( attacker );
    DamageScale = 0.0f;
    }
    return DamageScale;
    }
     
  2. Klokinator

    Klokinator Such Beta
    1. Aphelion's Roleplay

    Messages:
    1,443
    Am I reading this as... an archer shoots a knight, and gains Mind Control over said knight?
     
  3. sinitreo

    sinitreo Shopkeep Stealer
    1. Zen Laboratories

    Messages:
    66
    blob.PlugPlayer() ? o_O
     
  4. LightTab2

    LightTab2 Drill Rusher
    1. Zen Laboratories

    Messages:
    83
    Solved, thread to delete.