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

problem connecting node to a network.

Question

Did Chatbox , I know about Computronics , but would like to add a feature , namely the team that did not go to chat, that is, # hello, so that all chatboxs they will be push as an event , the problem is that in a single game and the server vanilla , it works , but in a thermos does not want to , I check computronics it works , apparently , I was wrong , debugging , I noticed that reachableNodes empty , all methods are implemented properly, and so if you try to take reachableNodes nodes Callback method annotated works , please help , not the first day of digging through the code .

 

Code:

https://github.com/Avaja/OpenTechnology/blob/master/src/main/java/OpenTechnology/tileentities/TileEntityAdminChatBox.java

Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 0

Hey Neo, I'm sorry if I don't understand your problem or what you're trying to do.  But from what you wrote it seems like you would like to be able to call a function and have all the chat boxes say the word you passed.  Something like this should work though, right?

local com = require "component"

local function speak(phrase, distance, name)
	for address, componentType in com.list("chat_box") do
		com.invoke(address,"setName", name)
		com.invoke(address,"say", phrase, distance)
	end
end


speak("say my name", 10, "Jimmy")
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

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