nostopgmaming17

anomic phone functions

Dec 3rd, 2021 (edited)
1,059
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local function r(...)
  2.     return game:GetService("ReplicatedStorage"):FindFirstChild("_CS.Events").TravelMessage:InvokeServer(...)
  3. end
  4. local function send(p,msg)
  5.     local R,m = {r("PrivateMessage",p,msg)}
  6.     if not R and m ~= "This player has their phone turned off." then
  7.         repeat
  8.             R,m = r("PrivateMessage",p,msg)
  9.             if m == "This player has their phone turned off." then break end
  10.             wait()
  11.         until R
  12.     end
  13.     return R,m
  14. end
  15. local function advertise(msg)
  16.     return r("Advertisement",msg)
  17. end
  18. local function forceadvertise(msg)
  19.     for i,v in next, game.Players:GetPlayers() do
  20.         spawn(function() send(v,msg) end)
  21.     end
  22. end
  23. return {
  24.     send = send;
  25.     advertise = advertise;
  26.     forceadvertise = forceadvertise;
  27. }
RAW Paste Data