This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
FireHead996's profile picture

[MC 1.7.10][CC 1.74] FirePeripherals V1.0

Started by FireHead996, 01 September 2015 - 12:02 AM
FireHead996 #1
Posted 01 September 2015 - 02:02 AM
FirePeripherals

What is this?
FirePeripherals is a pack of peripherals (obviously) for ComputerCraft that are meant to be connected to a LAN cable and can be used for various things. Actually, this pack contains:
- Redstone I/O Block (reading and emitting a redstone signal)
- Bundled I/O Block (reading and emitting a bundled cable signal from Project Red)
- Entity Detector Block (detecting an entity)

Recipes

Redstone I/O Block
Spoiler

Bundled I/O Block
Spoiler

Entity Detector Block
Spoiler

Code

Redstone I/O Block
Spoiler

redio = peripheral.wrap("rio_1")

redio.setOutput(true) -- enables a redstone signal with strength 15
redio.setOutput(false)   -- disables the redstone signal
redio.setOutput(10)  -- outputs a redstone signal of 10
redio.setOutput(0)  -- disables the redstone signal
redio.getInput()  -- returns true/false if there is a redstone signal or not (any strength)
redio.getAnalogInput()   -- returns an integer from 0-15 of the redstone strength


event, state, strength, id = os.pullEvent("redstone")  -- pulls an event with 4 return values
-- event returns:  redstone
-- state returns true/false if there is redstone
-- strength returns an integer from 0-15 indicating the redstone strength
-- id returns the id of the peripheral that threw the event

Bundled I/O Block
Spoiler

bundledio = peripheral.wrap("bio_1")

bundledio.getBundledInput() -- returns an integer indicating bundled signal on input
bundledio.getBundledOutput()   -- return an integer indicating bundled signal outputting by this block
bundledio.setBundledOutput(2)  -- outputs a bundled signal on orange cable
bundledio.testBundledInput(2)  -- returns true/false if there is a orange bundled signal or not
bundledio.testBundledOutput(1)  -- returns true/false if this block is emitting a white bundled signal or not


event, input, id = os.pullEvent("redstone")  -- pulls an event with 3 return values
-- event returns:  redstone
-- input returns an integer indicating the bundled signal
-- id returns the id of the peripheral that threw the event

Entity Detector Block
Spoiler

entityd = peripheral.wrap("edio_1")

entityd.getLastEntityName() -- return an string indicating last detected entity


event, entityName, id = os.pullEvent("detector")  -- pulls an event with 3 return values
-- event returns:  detector
-- entityName returns an string indicating detected entity
-- id returns the id of the peripheral that threw the event


How to install it?
Simply put the .jar file to your mods folder.
Remember! This pack needs ComputerCraft and ProjectRed to work fine. If you don't have them, pack might be buggy.

Link for project on Curse
Click!

Changelog
- V1.0: Initial release
Edited on 22 October 2015 - 06:31 PM
acces denied #2
Posted 02 September 2015 - 04:31 PM
I love this! I've been waiting for this since 1.6.4. May I suggest uploading this to the forge-curse network? Anyway, very good work!
FireHead996 #3
Posted 02 September 2015 - 10:42 PM
Added project on Curse. :)/>
master39 #4
Posted 06 November 2015 - 08:10 AM
Question, there is a way to ignore the project-red requirement?
FireHead996 #5
Posted 07 November 2015 - 06:19 AM
Simply not crafting and placing a bundled controller. :P/> If you give me some time, i update it with a config file so it will be possibility to turn off individual block. :)/>
Creator #6
Posted 07 November 2015 - 08:09 AM
We already have that in standard CC, so convince me to get the peripherals :P/>
Edited on 07 November 2015 - 07:09 AM
FireHead996 #7
Posted 07 November 2015 - 11:04 AM
Main idea of this mod is to extend capabilities for connecting things to computers. From one side, you can connect more cables to one computer, and from another, you can control one cable (element) from more than one computer in the network. :)/>
Creator #8
Posted 07 November 2015 - 11:07 AM
This is pretty convincing. Thanks.
happysmash27 #9
Posted 13 April 2016 - 02:12 AM
Could you please add a link which is not on Curse? The CSS and javascript on both Curse and Minecraft Forum are messed up for me for some reason, meaning the download doesn't work.
SquidDev #10
Posted 13 April 2016 - 07:28 AM
Could you please add a link which is not on Curse? The CSS and javascript on both Curse and Minecraft Forum are messed up for me for some reason, meaning the download doesn't work.

This might work. Its an (almost-)direct link to the Jar on CurseForge.