Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class Switch : MonoBehaviour
- {
- public GameObject VladHead;
- public GameObject VladRightArm;
- public GameObject VladLeftArm;
- public GameObject VladRightUpperLeg;
- public GameObject VladRightLeg;
- public GameObject VladRightFoot;
- public GameObject VladLeftUpperLeg;
- public GameObject VladLeftLeg;
- public GameObject VladLeftFoot;
- public GameObject VladTorso;
- public GameObject GabrielaHead;
- public GameObject GabrielaRightArm;
- public GameObject GabrielaLeftArm;
- public GameObject GabrielaRightUpperLeg;
- public GameObject GabrielaRightLeg;
- public GameObject GabrielaRightFoot;
- public GameObject GabrielaLeftUpperLeg;
- public GameObject GabrielaLeftLeg;
- public GameObject GabrielaLeftFoot;
- public GameObject GabrielaTorso;
- public GameObject AlinHead;
- public GameObject AlinRightArm;
- public GameObject AlinLeftArm;
- public GameObject AlinRightUpperLeg;
- public GameObject AlinRightLeg;
- public GameObject AlinRightFoot;
- public GameObject AlinLeftUpperLeg;
- public GameObject AlinLeftLeg;
- public GameObject AlinLeftFoot;
- public GameObject AlinTorso;
- public GameObject Character;
- // Use this for initialization
- void Start()
- {
- Character.tag = "Vlad";
- VladHead.SetActive(true);
- VladRightArm.SetActive(true);
- VladLeftArm.SetActive(true);
- VladRightUpperLeg.SetActive(true);
- VladRightLeg.SetActive(true);
- VladRightFoot.SetActive(true);
- VladLeftUpperLeg.SetActive(true);
- VladLeftLeg.SetActive(true);
- VladLeftFoot.SetActive(true);
- VladTorso.SetActive(true);
- GabrielaHead.SetActive(false);
- GabrielaRightArm.SetActive(false);
- GabrielaLeftArm.SetActive(false);
- GabrielaRightUpperLeg.SetActive(false);
- GabrielaRightLeg.SetActive(false);
- GabrielaRightFoot.SetActive(false);
- GabrielaLeftUpperLeg.SetActive(false);
- GabrielaLeftLeg.SetActive(false);
- GabrielaLeftFoot.SetActive(false);
- GabrielaTorso.SetActive(false);
- AlinHead.SetActive(false);
- AlinRightArm.SetActive(false);
- AlinLeftArm.SetActive(false);
- AlinRightUpperLeg.SetActive(false);
- AlinRightLeg.SetActive(false);
- AlinRightFoot.SetActive(false);
- AlinLeftUpperLeg.SetActive(false);
- AlinLeftLeg.SetActive(false);
- AlinLeftFoot.SetActive(false);
- AlinTorso.SetActive(false);
- }
- // Update is called once per frame
- void Update()
- {
- if (Input.GetKeyDown(KeyCode.P))
- {
- Character.tag = "Vlad";
- VladHead.SetActive(true);
- VladRightArm.SetActive(true);
- VladLeftArm.SetActive(true);
- VladRightUpperLeg.SetActive(true);
- VladRightLeg.SetActive(true);
- VladRightFoot.SetActive(true);
- VladLeftUpperLeg.SetActive(true);
- VladLeftLeg.SetActive(true);
- VladLeftFoot.SetActive(true);
- VladTorso.SetActive(true);
- GabrielaHead.SetActive(false);
- GabrielaRightArm.SetActive(false);
- GabrielaLeftArm.SetActive(false);
- GabrielaRightUpperLeg.SetActive(false);
- GabrielaRightLeg.SetActive(false);
- GabrielaRightFoot.SetActive(false);
- GabrielaLeftUpperLeg.SetActive(false);
- GabrielaLeftLeg.SetActive(false);
- GabrielaLeftFoot.SetActive(false);
- GabrielaTorso.SetActive(false);
- AlinHead.SetActive(false);
- AlinRightArm.SetActive(false);
- AlinLeftArm.SetActive(false);
- AlinRightUpperLeg.SetActive(false);
- AlinRightLeg.SetActive(false);
- AlinRightFoot.SetActive(false);
- AlinLeftUpperLeg.SetActive(false);
- AlinLeftLeg.SetActive(false);
- AlinLeftFoot.SetActive(false);
- AlinTorso.SetActive(false);
- }
- if (Input.GetKeyDown(KeyCode.O))
- {
- Character.tag = "Gabriela";
- VladHead.SetActive(false);
- VladRightArm.SetActive(false);
- VladLeftArm.SetActive(false);
- VladRightUpperLeg.SetActive(false);
- VladRightLeg.SetActive(false);
- VladRightFoot.SetActive(false);
- VladLeftUpperLeg.SetActive(false);
- VladLeftLeg.SetActive(false);
- VladLeftFoot.SetActive(false);
- VladTorso.SetActive(false);
- GabrielaHead.SetActive(true);
- GabrielaRightArm.SetActive(true);
- GabrielaLeftArm.SetActive(true);
- GabrielaRightUpperLeg.SetActive(true);
- GabrielaRightLeg.SetActive(true);
- GabrielaRightFoot.SetActive(true);
- GabrielaLeftUpperLeg.SetActive(true);
- GabrielaLeftLeg.SetActive(true);
- GabrielaLeftFoot.SetActive(true);
- GabrielaTorso.SetActive(true);
- AlinHead.SetActive(false);
- AlinRightArm.SetActive(false);
- AlinLeftArm.SetActive(false);
- AlinRightUpperLeg.SetActive(false);
- AlinRightLeg.SetActive(false);
- AlinRightFoot.SetActive(false);
- AlinLeftUpperLeg.SetActive(false);
- AlinLeftLeg.SetActive(false);
- AlinLeftFoot.SetActive(false);
- AlinTorso.SetActive(false);
- }
- if (Input.GetKeyDown(KeyCode.I))
- {
- Character.tag = "Alin";
- VladHead.SetActive(false);
- VladRightArm.SetActive(false);
- VladLeftArm.SetActive(false);
- VladRightUpperLeg.SetActive(false);
- VladRightLeg.SetActive(false);
- VladRightFoot.SetActive(false);
- VladLeftUpperLeg.SetActive(false);
- VladLeftLeg.SetActive(false);
- VladLeftFoot.SetActive(false);
- VladTorso.SetActive(false);
- GabrielaHead.SetActive(false);
- GabrielaRightArm.SetActive(false);
- GabrielaLeftArm.SetActive(false);
- GabrielaRightUpperLeg.SetActive(false);
- GabrielaRightLeg.SetActive(false);
- GabrielaRightFoot.SetActive(false);
- GabrielaLeftUpperLeg.SetActive(false);
- GabrielaLeftLeg.SetActive(false);
- GabrielaLeftFoot.SetActive(false);
- GabrielaTorso.SetActive(false);
- AlinHead.SetActive(true);
- AlinRightArm.SetActive(true);
- AlinLeftArm.SetActive(true);
- AlinRightUpperLeg.SetActive(true);
- AlinRightLeg.SetActive(true);
- AlinRightFoot.SetActive(true);
- AlinLeftUpperLeg.SetActive(true);
- AlinLeftLeg.SetActive(true);
- AlinLeftFoot.SetActive(true);
- AlinTorso.SetActive(true);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement