private void Update() { while (!player_Con) { player_Con = gameObject.transform.root.GetComponent <Player_controll>(); } }
public void Attach(Player_controll player_con) { player_con.char_now.speed += speed * player_con.char_now.item_power; player_con.char_now.weight += weight * player_con.char_now.item_power; player_con.char_now.jump += jump * player_con.char_now.item_power; player_con.char_now.jump_point_max += jump_point * player_con.char_now.item_power; if (player_con.char_now.speed < player_con.char_now.speed_min) { player_con.char_now.speed = player_con.char_now.speed_min; } if (player_con.char_now.weight < player_con.char_now.weight_min) { player_con.char_now.weight = player_con.char_now.weight_min; } if (player_con.char_now.jump < player_con.char_now.jump_min) { player_con.char_now.jump = player_con.char_now.jump_min; } if (player_con.char_now.jump_point_max < player_con.char_now.jump_point_max_min) { player_con.char_now.jump_point_max = player_con.char_now.jump_point_max_min; } }