void Start() { ArmRB = transform.parent.rigidbody; isLeft = transform.parent.gameObject.name == "Left Arm"; target = ArmRB.transform.rotation; Guy = transform.parent.parent.gameObject.GetComponent<Guy>(); }
IEnumerator StopUpright(Guy guy) { guy.DontConnect = true; guy.uprightStrength = 0.0f; yield return new WaitForSeconds(2.0f); guy.uprightStrength = 1.0f; guy.DontConnect = false; }
static void Main(string[] args) { Guy guy = new Guy("Joe", 43, 125); HiThereWriter.HiThere(guy.Name); HiThrereWriterCLI.HiThere(guy.Name); string str1 = "abcd汉字efgh"; MessageBox.Show(String.Format("\"{0}\" length: {1}", str1, HiThrereWriterCLI.ComputeLength(str1))); }
private void btnCarregarJoe_Click(object sender, EventArgs e) { using (Stream input = File.Open("Guy_Joe.dat", FileMode.Open)) { BinaryFormatter bf = new BinaryFormatter(); joe = (Guy) bf.Deserialize(input); } UpdateForm(); }
public Form1() { InitializeComponent(); bob = new Guy(); bob.Name = "bob"; bob.Cash = 100; joe = new Guy(); joe.Name = "joe"; joe.Cash = 50; UpdateForm(); }
public Form1() { InitializeComponent(); joe = new Guy(); joe.name = "Joe"; joe.cash = 50; bob = new Guy(); bob.name = "Bob"; bob.cash = 100; UpdateForm(); }
protected void OnButton1Clicked(object sender, EventArgs e) { int cont = 0; for (var i1=0;i1<5;i1++) { cont= cont+1; Guy g1= new Guy("yellow",e2.Text,"Kools",1,e5.Text,"Norwegian"); Guy g2= new Guy("blue","horse",e9.Text,2,e11.Text,e12.Text); Guy G3 = new Guy(e13.Text,e14.Text,e15.Text,3,"Milk",e18.Text); Guy G4 = new Guy(e19.Text,e20.Text,e21.Text,4,e23.Text,e24.Text); Guy G5 = new Guy(e25.Text,e26.Text,e27.Text,5,e29.Text,e30.Text); e1.Text="yellow"; e2.Text=g1.SAnimal; e3.Text=g1.SSmoke; e4.Text="1"; e5.Text=g1.SDrink; e6.Text="Norwegian"; e7.Text="blue"; e8.Text="horse"; e9.Text=g2.SSmoke; e10.Text="2"; e11.Text=g2.SDrink; e12.Text=g2.SCountry; e13.Text=G3.SHouseColor; e14.Text=G3.SAnimal; e15.Text=G3.SSmoke; e16.Text="3"; e17.Text="Milk"; e18.Text=G3.SCountry; e19.Text=G4.SHouseColor; e20.Text=G4.SAnimal; e21.Text=G4.SSmoke; e22.Text="4"; e23.Text=G4.SDrink; e24.Text=G4.SCountry; e25.Text=G5.SHouseColor; e26.Text=G5.SAnimal; e27.Text=G5.SSmoke; e28.Text="5"; e29.Text=G5.SDrink; e30.Text=G5.SCountry; } }
public void Draw(Guy guy, SpriteBatch spriteBatch, GameTime gameTime, SpriteEffects spriteEffects) { _sprite.Draw(spriteBatch, guy.Physics.Position, spriteEffects); }
public void Exit(Guy guy) { }
public void Enter(Guy guy, GameTime gameTime) { }
static void Main(string[] args) { Guy guy = new Guy("Joe", 43, 125); HiThereWriter.HiThere(guy.Name); }