Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

what's wrong with my code?

Discussion in 'UGUI & TextMesh Pro' started by Weirhu, Apr 5, 2015.

  1. Weirhu

    Weirhu

    Joined:
    Feb 21, 2015
    Posts:
    5
    Code (CSharp):
    1. using UnityEngine;
    2. using System.Collections;
    3. using UnityEngine.UI;
    4. using UnityEngine.EventSystems;
    5.  
    6.  
    7. public class logintoloading : MonoBehaviour, IPointerClickHandler {
    8.  
    9.  
    10.    
    11.  
    12.     public void OnPionterClick (PointerEventData eventData) {
    13.         Application.LoadLevel ("loadingUI");
    14.    
    15.     }
    16. }
    17.  
    the warning is "Assets/script/logintoloading.cs(7,14): error CS0535: `logintoloading' does not implement interface member `UnityEngine.EventSystems.IPointerClickHandler.OnPointerClick(UnityEngine.EventSystems.PointerEventData)'"
    I am a newbie of coding, pls kindly help me. thanks very much.
     
  2. Dantus

    Dantus

    Joined:
    Oct 21, 2009
    Posts:
    5,667
    I would try OnPointerClick instead of OnPionterClick ;)
     
  3. Weirhu

    Weirhu

    Joined:
    Feb 21, 2015
    Posts:
    5
    ....omg.. :mad:
     
    malek8 likes this.