14 posts
Posted 12 December 2015 - 07:43 PM
Hi Computercraft Forum,
I wanted to ask how the openperipheral glasses with the prefix $$ for a program.
How is it done?
please help me!!
2427 posts
Location
UK
Posted 12 December 2015 - 08:12 PM
when you say something in chat with $$ as a prefix while wearing the glasses, the computer linked to the glasses gets an event, one of the parameters of this event is the message that you typed into chat
Edited on 12 December 2015 - 07:13 PM
1080 posts
Location
In the Matrix
Posted 12 December 2015 - 09:08 PM
How to find that event:
while true do
local event = os.pullEvent()
print(event)
end
Run this code on a machine with the bridge next to it, then type the $$ prefix while you're wearing the linked pair of glasses. This will tell you what event you need to look for (and possibly look up on google for an easier time)
14 posts
Posted 18 December 2015 - 08:13 PM
Thanks