Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal

danielrama30

Members
  • Content Count

    3
  • Joined

  • Last visited

About danielrama30

  • Rank
    Junior Member

Contact Methods

  • Minecraft
    danielrama30
  1. In the computer: --Setting libraries local component = require("component") local term = require("term") local event = require("event") local modem = component.modem --Program code modem.open(111) term.clear() print(">") term.setCursor(2,1) input = io.read() if input == "server.status" then modem.send("address of the server", 123, input) os.sleep(2) local _,_,_,_,_,status = event.pull("modem") print("Server status: " .. status) else print("Illegal command") end In the server: --Setting libraries local component = require("component") local term = require("term") local event = require("event") local modem = component.modem --Program code modem.open(123) while true do local _,_,remoteNetwork,_,_,input = event.pull("modem_message") print("Command received: " .. input) if input == "server.status" then modem.send(remoteNetwork, 111, "Online") else modem.send(remoteNetwork, 111, " ") end end I tried with modem.send() and modem.broadcast() but nothing changes.
  2. Hello everyone. I have a problem with the server rack the commands mentioned in the title of the thread. I have to send a message from the server to a computer.....but the problem is that he receives messages from other computers but not send them. I tried to use programs and single commands but still not work. I wrote this on the server: component.modem.broadcast("111, "test") or component.modem.send({computer address}, 111, "test") And this on the computer: =event.pull("modem_message") I used the relay to realize that it is the server doesn't send messages because it doesn't blink. (Not sure I wrote correctly, I'm not english.) Every method I try doesn't work. Nobody else has had this problem? Can someone help me?
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.