Jump to content




[mc 1.6.x] Openperipheral


  • This topic is locked This topic is locked
1184 replies to this topic

#761 blockly

  • Members
  • 41 posts
  • LocationSan Francisco, California, USA

Posted 16 October 2013 - 06:53 PM

View Posttheoriginalbit, on 16 October 2013 - 06:35 PM, said:

Try it in a crafting table, if that doesn't work then the version that you have does not support a sensor on a Turtle, meaning that you'll have to get the Turtle to pickup and move the sensor with it.

Thanks for the suggestion. I should have mentioned that I'm using the newest version of OpenPeripheral from the github repository [https://github.com/O...penPeripheral].

I tried placing a sensor immediately above a turtle using a crafting table, as you suggested, but the recipe wasn't recognized.

What version does support sensors on turtles?

Thanks.

#762 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 16 October 2013 - 07:01 PM

You're not using the latest now I pushed through a commit about 30 mins ago ;) Also use this site, Jenkins does a build each time something is commited to GitHub, so it removes the need for you to build it.

I'm not too sure when the support started, but the current version supports it, you have to put it in the crafting table like you would any Turtle peripheral, on the left or right of the Turtle.

#763 blockly

  • Members
  • 41 posts
  • LocationSan Francisco, California, USA

Posted 16 October 2013 - 07:04 PM

View Posttheoriginalbit, on 16 October 2013 - 07:01 PM, said:

You're not using the latest now I pushed through a commit about 30 mins ago ;)
:D

View Posttheoriginalbit, on 16 October 2013 - 07:01 PM, said:

Also use this site, Jenkins does a build each time something is commited to GitHub, so it removes the need for you to build it.

Thanks for the link, although eventually I'll be modifying the source.

View Posttheoriginalbit, on 16 October 2013 - 07:01 PM, said:

I'm not too sure when the support started, but the current version supports it, you have to put it in the crafting table like you would any Turtle peripheral, on the left or right of the Turtle.

I hadn't even realized that was how to put them together. I'd be just placing them on adjacent blocks.

#764 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 16 October 2013 - 07:06 PM

View Postblockly, on 16 October 2013 - 07:04 PM, said:

I hadn't even realized that was how to put them together. I'd be just placing them on adjacent blocks.
The code isn't controlled by OpenPeripheral, its controlled by ComputerCraft, and ComputerCraft logic states that you have to put the peripherals on the left or right, hence when putting pickaxes and such on the side it will work.

#765 blockly

  • Members
  • 41 posts
  • LocationSan Francisco, California, USA

Posted 17 October 2013 - 06:33 PM

I must not be understanding your instructions, Bit, because I still can't combine a computer/turtle and sensor.

I'm running:
  • MC 1.6.4
  • MCP v8.11
  • FML 6.4.8.886
  • MinecraftForge 9.11.0.886
  • ComputerCraft 1.57 [child mod: ComputerCraft Turtles]
  • OpenPeripheral 0.2.1-forge9.11.0.883-snapshot-68.jar (from the download link you shared)
When I start a game in creative mode, I can find ComputerCraft and OpenPeripheral tabs in my inventory, and I can drag out computers, turtles, and sensors. When I open a crafting table and place a {computer or turtle} and sensor next to each other, no output is offered. Is there a certain version of computer/turtle I need to use or sensor placement?

Posted Image

FWIW, I have no trouble getting the computer and sensor to communicate with each other when placed adjacent to each other in the world:
Posted Image

I really appreciate your help.

#766 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 17 October 2013 - 11:35 PM

View Postblockly, on 17 October 2013 - 06:33 PM, said:

-snip-

A computer cannot be crafted with a sensor, it does not support peripherals in that way, only Turtles can be crafted with sensors.

Crafting a Turtle with a sensor
Spoiler

Result
Spoiler

Since you're very new to ComputerCraft I suggest that you read the following Tutorials:
Computer Basics 1
Computer Basics 2
Peripheral Basics
Turtle Basics

#767 blockly

  • Members
  • 41 posts
  • LocationSan Francisco, California, USA

Posted 18 October 2013 - 09:54 AM

Thank you so much, both for the information and for your diplomacy. I had read the first two tutorials but had not seen the last two.

#768 blockly

  • Members
  • 41 posts
  • LocationSan Francisco, California, USA

Posted 18 October 2013 - 05:50 PM

I've read the tutorials and succeeded in building a turtle that has a pickaxe and a sensor, as well as modifying the behavior of the sonicScan() method. Thanks for your help and patience.

I would like to be able to tell the direction that the turtle is facing in a LuaMethod called on a sensor turtle. As you know, the signature of the LuaMethod is:
(IComputerAccess computer, ISensorEnvironment env)

I can test whether the attached device is a turtle with env.isTurtle(), but I'm unable to figure out how to call the ITurtleAccess method getFacingDir(). I was hoping that ITurtleAccess was a sub-interface of IComputerAccess, but no such luck. How does an attached peripheral access the ITurtleAccess interface?

Thanks.

#769 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 18 October 2013 - 11:17 PM

No problems, any time.

I guess the easiest way, would be to create a new method in the openperipheral.turtleTurtleSensorEnvironment to get the ITurtleAccess object which you can call getFacingDir on. then in sonicScan just put in the facing direction? the reason I say sonicScan is there is no way in an adapter to specify that a method is for a specific type of computer (computer or turtle) so if you want to do a new method, you'll have to implement a way, so that you do not see getFacingDir on a computer as well.

Also once you've got the direction, which is a number, you may want to convert it into a more easily readable string.

If anything was able to be cast, it'd be the ISensorEnvironment before the IComputerAccess as the env variable is where the TileEntity is passed through.

#770 Anti

  • New Members
  • 1 posts

Posted 19 October 2013 - 12:53 PM

Hello Everyone!
The inventory functions regarding item movement don't seem to be working. I'm doing everything like in the example in the documentation but i get a attempt to call nil every time i use them. And yes, they are enabled in the config. I'm using build 68.

Future Anti says thanks for your help. ;-)

#771 Iomega0318

  • Members
  • 6 posts

Posted 19 October 2013 - 01:41 PM

So I was curious, is the version released right now, 0.2.1 I believe, have the needed changes to work like the Nexus direwolf created here:
https://www.youtube....h?v=z6RmM7KP150
I tried using it but it doesn't seem to be working.. or I broke something lol..

#772 Geforce Fan

  • Members
  • 846 posts
  • LocationMissouri, United States, America, Earth, Solar System, Milky Way, Universe 42B, Life Street, Multiverse, 4th Dimension

Posted 19 October 2013 - 02:22 PM

How do you use the mechs? I'm seeing them in the creative tab and want to use them.

#773 LaughingLeader

  • Members
  • 9 posts

Posted 19 October 2013 - 04:21 PM

View PostAnti, on 19 October 2013 - 12:53 PM, said:

Hello Everyone!
The inventory functions regarding item movement don't seem to be working. I'm doing everything like in the example in the documentation but i get a attempt to call nil every time i use them. And yes, they are enabled in the config. I'm using build 68.

Future Anti says thanks for your help. ;-)
The method names in the OpenPeripheral documentation are incorrect, I believe.

Inventories (chests, etc) use these methods:

Quote

getInventoryName
getInventorySize
getStackInSlot
swapStacks
condenseItems
pushItem
pushItemIntoSlot
pullItem
pullItemIntoSlot
You'll notice in the OpenPeripheral documentation that these names are slightly different, like how what should be "pushItem()" is labelled as "push()", "getInventoryName()" is labelled as "getInvName()", and so on. Since you can't really go by the documentation till it's updated, I recommend making a test computer and doing something like this to check the method names of peripherals:

local side = "top";
local methods = peripheral.getMethods(side);
print("Methods:")
for i=1, #methods do
print(i.." = "..methods[i]);
end

Hope that helps.

#774 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 October 2013 - 12:32 AM

View PostAnti, on 19 October 2013 - 12:53 PM, said:

-snip-

View PostLaughingLeader, on 19 October 2013 - 04:21 PM, said:

-snip-
LaughingLeader is 100% correct, the method names have changed in the 1.6.x version of OpenPeripheral, unfortunately I think the documentation will not be updated until there is an official release of the 1.6.4 version.

View PostIomega0318, on 19 October 2013 - 01:41 PM, said:

-snip-
No ForgeCraft2 is using a newer version than 0.2.1, they are using a fairly recent build, if not the more recent. This means that there would be different method names as well as new features like being able to read linking books.

View PostHithere__, on 19 October 2013 - 02:22 PM, said:

-snip-
Mechs are currently craft-able with a temporary recipe, however the controller does not, if you're wanting to use in survival you'll have to cheat them in. As for how to use them, place the controller beside the computer and run listMethods on it to see everything available to do with the MechWarrior.

#775 vvenaya

  • Members
  • 27 posts

Posted 20 October 2013 - 07:52 AM

Silislime is not craftable with IC2 installed ...

An option for an alternative recipe would be most welcome, otherwise this mod is just useless to me (and others)

#776 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 October 2013 - 08:23 AM

View Postvvenaya, on 20 October 2013 - 07:52 AM, said:

Silislime is not craftable with IC2 installed ...

An option for an alternative recipe would be most welcome, otherwise this mod is just useless to me (and others)
Uhhh which IC2 recipe is it that changes it exactly? I am on a server that is running all the latest mods, including IC2 and we have no problem at all with making Silislime Rubber. We have several sensors in use. I would also like to address your "this mod is just useless to me (and others)" statement. With a few of my own:

1. It seems that you're using a build on the 1.6.4 branch, this is not yet an official release, nothing is final and subject to change
2. OpenCCSensors has only fairly recently been merged with OpenPeripheral, there may be things to still work out
3. Taking the former point into consideration, OpenPeripheral's purpose as a mod is to add a plethora of support of different mods into ComputerCraft for use as a peripheral, whether its being able to interact with the mod's items, or just be able to read information from it. This mod has a far greater usage beyond the sensors, and I'm sorry if you feel that is all that this mod is "useful for"
4. If you are in fact using the silislime to craft a MechWarrior please see my post above yours for more information.

#777 vvenaya

  • Members
  • 27 posts

Posted 20 October 2013 - 09:06 AM

Silislime is created by burning slimeball in a furnace ...
IC2 overrides this recipe to create sticky resin (in any furnace)

Looking in NEI, we don't get a recipe to create silislime, which proves my point of it being overritten by IC2

IC2 has had this recipe since forever, and i am surprised that this was not noticed by the openperipheral authors.

I mainly wanted openperipherals to be used for it's glass (on display HUD) functionality, but nearly all recipes there require silislime.


Further info:
We use MC 1.6.2 with IC2 experimental (latest version)

#778 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 October 2013 - 09:28 AM

View Postvvenaya, on 20 October 2013 - 09:06 AM, said:

IC2 overrides this recipe to create sticky resin (in any furnace)
IC2 has had this recipe since forever
I cannot find any evidence of your claims of being able to make sticky resin from slimeballs and I know that silislime is made with it!
IC2 Wiki
Another Wiki
Tekkit Wiki
Screenshot (instance has IC2 Experimental + OpenPeripheral)
I definitely cannot replicate on my instance. What other mods are you using? I think Gregtech does it?

#779 vvenaya

  • Members
  • 27 posts

Posted 20 October 2013 - 10:37 AM

GREGORIUST YOU EVIL BASTARD



It was indeed GregTech fouling things up. I have always used gregtech, and thought that he would not touch such things like slimeball smelting ... i was wrong

Found this is his config

smelting {
 B:item.slimeball_true=true
...
}





Sorry for causing a fuss, i should have investigated further

#780 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 October 2013 - 10:40 AM

View Postvvenaya, on 20 October 2013 - 10:37 AM, said:

-snip-
when there is something that's not normal with recipes, and GregTech is installed, assume GregTech, he messes with so much 9/10 it will be GregTech messing with it.


View Postvvenaya, on 20 October 2013 - 10:37 AM, said:

Sorry for causing a fuss, i should have investigated further
That's ok, that's what I'm here for, at the moment I'm the only developer that's providing user support on these forums. NeverCast said he was going to as well, but, well, he hasn't been :P





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users