当前位置:网站首页>2.10transfrom attribute
2.10transfrom attribute
2022-07-06 07:50:00 【The ji】
How to get more , You can put transfrom, Understand it as an attribute ( Every object can have attributes )
such as sl = transform.GetChild(0).GetComponent<Slider>(); He is slider In the properties of the . Location . Get components
game.transform.parent = Content.transform;
And he Content“ After acquiring her components , He still wants some transfrom attribute ”
Go and get game Class transfrom attribute , then .parent Properties of
1. Find components through code
2.playerImg.sprite=imgs[0].sprite; He means that one of his attributes is revealed through it ( stay image On )
3.sT.onClick.AddListener(jdbtn); //AddListener== Add method // Code acquisition button Click events for
1. The first 29 OK, he wants to name one using system Space , He gets time ( Or you could write it as System.DateTime.Now.Tostring(), No need to write namespace .)
2.30 OK, he added a name to the random number , Because random numbers are using system and unityEngince meanwhile
There is , So choose one
3.32-34 OK, he just clones an object ( Text ), Give to the Gameobject game, then To get the text , You need to ,game.getcomponent<text>().text . adopt Gameobject Class go , Get his components text.
parent Method represents a subclass of an object , So put the location attribute , Give it to him game Subclasses of classes .
as follows
边栏推荐
- Position() function in XPath uses
- edge浏览器 路径获得
- Binary tree creation & traversal
- In the era of digital economy, how to ensure security?
- The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
- Type of data in energy dashboard
- Méthode d'obtention des propriétés de l'objet JS (.Et [] méthodes)
- (lightoj - 1410) consistent verbs (thinking)
- 洛谷P4127 [AHOI2009]同类分布 题解
- [window] when the Microsoft Store is deleted locally, how to reinstall it in three steps
猜你喜欢
How to delete all the words before or after a symbol in word
[computer skills]
数据治理:主数据的3特征、4超越和3二八原则
Do you really think binary search is easy
In the era of digital economy, how to ensure security?
The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
软件测试界的三无简历,企业拿什么来招聘你,石沉大海的简历
[nonlinear control theory]9_ A series of lectures on nonlinear control theory
Leecode-c language implementation -15 Sum of three ----- ideas to be improved
随机推荐
The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
leecode-C語言實現-15. 三數之和------思路待改進版
Entity class design for calculating age based on birthday
Position() function in XPath uses
Description of octomap averagenodecolor function
Data governance: metadata management
Type of data in energy dashboard
octomap averageNodeColor函数说明
Full Score composition generator: living on code
esRally国内安装使用避坑指南-全网最新
Sharing of source code anti disclosure scheme under burning scenario
2022年Instagram运营小技巧简单讲解
P3047 [USACO12FEB]Nearby Cows G(树形dp)
C intercept string
Rust language - receive command line parameter instances
edge浏览器 路径获得
23. Update data
Inspiration from the recruitment of bioinformatics analysts in the Department of laboratory medicine, Zhujiang Hospital, Southern Medical University
js對象獲取屬性的方法(.和[]方式)
The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower