• Print

Author Topic: Need a command  (Read 4106 times)

0 Members and 1 Guest are viewing this topic.

Offline XxLMM13xX

  • Sr. Member
  • ****
  • Posts: 265
  • Karma: -51
  • New to lua development
    • Twitch
Need a command
« on: November 14, 2014, 05:38:54 pm »
Yes i know i asked this another time before but can i get a command that is call website that opens with  !website and opens to a link. Just put the link to google and ill change it.

Thanks!!!

Offline bender180

  • Full Member
  • ***
  • Posts: 217
  • Karma: 42
    • Benders Villa
Re: Need a command
« Reply #1 on: November 15, 2014, 07:39:34 am »
next time use the forum search this has been posted at least two dozen times,

Code: Lua
  1. function webCommand( pl, text, teamonly )
  2.                     if (text == "!website") then
  3.                             pl:SendLua([[gui.OpenURL("http://www.google.ca/")]]) -- Change ADDRESS to your chosen page.
  4.                             for k, v in pairs(player.GetAll()) do v:ChatPrint( "Player " .. pl:Nick() .. " has visited our website." )
  5.  
  6.                 end
  7.         end
  8. end
  9. hook.Add( "PlayerSay", "Chat", webCommand )
Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
Also made the ttt ulx commands.

Offline XxLMM13xX

  • Sr. Member
  • ****
  • Posts: 265
  • Karma: -51
  • New to lua development
    • Twitch
Re: Need a command
« Reply #2 on: November 15, 2014, 08:31:26 am »
Thank you so much!!!!

  • Print