Inheritance: MonoBehaviour
Example #1
0
    public override void OnInspectorGUI()
    {
        testscript ts = target as testscript;

        pSel = ts.e.DrawInspector(pSel);

        GUILayout.Label("has payload? " + (ts.e.payload != null));
        GUILayout.Label("payload type? " + ts.e.payload.GetType().ToString());

        DrawDefaultInspector();
    }
Example #2
0
    //-------------------------//

    // Start is called before the first frame update
    void Start()
    {
        actualDrag       = GetComponent <Rigidbody>().drag;
        inmuneTimer      = 0;
        cmp_test         = GetComponent <testscript>();
        cmp_modelo_Ply   = GetComponent <PlayerModelo>();
        cmp_plyView      = GetComponent <PlayerView>();
        cmp_grnd_Updater = GetComponent <GroundStatsUpdater>();
        cmp_mov          = GetComponent <Movement>();
        cmp_rot          = GetComponent <Rotatement>();
        cmp_atk          = GetComponent <Attacks>();
        cmp_timers       = GetComponent <TimersNTools>();
        cmp_life         = GetComponent <Life>();
        cmp_life.life    = cmp_modelo_Ply.playerLife;
        protecting       = false;
        cmp_life.protec  = protecting;
    }
Example #3
0
 public virtual void Interact(testscript player)
 {
     player.Controllable = false;
     TextBox.Create(this, "Interaction is live boys", () => player.Controllable = true);
 }