Q14.webp
T

Q14.webp

Kizspy | Question: 14
(Choose 1 answer)
How can this script be triggered by a UI Button in Unity?
using UnityEngine;
public class UIButton: MonoBehaviour {
public void OnClick() {
Debug.Log("Button Clicked!");
A. Attach it to a GameObject and call it in Update()
B. Assign it to the Button's OnClick event in the Inspector
C. Add it to the Canvas component
D. Use it in the Animator Controller

Thông tin

Category
FGU301
Thêm bởi
thuyhoa276
Ngày thêm
Lượt xem
236
Lượt bình luận
1
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom