Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate
Collapse

Plutonium

  1. Home
  2. BO2 Modding Support & Discussion
  3. [Help]Function List

[Help]Function List

Scheduled Pinned Locked Moved BO2 Modding Support & Discussion
2 Posts 2 Posters 103 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • luisinoooooundefined Offline
    luisinoooooundefined Offline
    luisinooooo
    wrote on last edited by
    #1

    Hello dear community,
    Im trying to develop my custom scripts, idk, basic stuff like commands in the chat, giving money to players ...etc

    Currently, I have approached giving money when a player spanws, however, I want to do it when a player type in the chat something like ".givemoney"

    I tried to find out how does the chat work, however, I keep getting crashed each time.

    I leave you my code here

    init()
    {
    	level thread watchChatMessages();
    }
    
    watchChatMessages()
    {
       level endon("end_game");
       for(;;) {
          level waittill("say", player, message);
          if (message == ".givemoney") {
             player.score += 100;
          }
          wait 0.01;
       }
    }
    

    If you can bring me a page where the function list are listed, due to I couldn't find them too.
    Thanks for reading, best regards.

    JezuzLizardundefined 1 Reply Last reply
    0
    • JezuzLizardundefined Offline
      JezuzLizardundefined Offline
      JezuzLizard Plutonium Staff
      replied to luisinooooo on last edited by
      #2

      luisinooooo

      Its

      level waittill("say", message, player);
      
      1 Reply Last reply
      1

      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Donate