Help Meeeee

Discussion in 'Facepalm' started by WoolChannel3295, Mar 1, 2020.

  1. WoolChannel3295

    WoolChannel3295 Silverfish

    Messages:
    22
    GitHub:
    KietTran0308
    Why does the public function onEnable () {need it: void after the () ??
    upload_2020-3-2_0-52-6.png
     
  2. HimbeersaftLP

    HimbeersaftLP Fish

    Messages:
    2,401
    GitHub:
    HimbeersaftLP
    The : indicates a return typehint. The void indicated nothing.
    : void means that the function returns nothing.
     
    GamakCZ likes this.
  3. WoolChannel3295

    WoolChannel3295 Silverfish

    Messages:
    22
    GitHub:
    KietTran0308
    So when to use: void or always use: void
     
  4. DaRealPandaz

    DaRealPandaz Silverfish

    Messages:
    24
    GitHub:
    mrpandaz
    It is not required. It is good to have though.
     
  5. kriskotooBG

    kriskotooBG Spider Jockey

    Messages:
    46
    GitHub:
    kriskotoobg

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.