openmods / openperipheral Goto Github PK
View Code? Open in Web Editor NEWHome Page: https://openmods.info
License: MIT License
Home Page: https://openmods.info
License: MIT License
LanteaCraft is an improved remake of SGcraft. It appears OpenPeripheral is having difficulties to handle it:
2014-02-02 13:31:31 [Avertissement] [OpenMods] Integration module 'SGCraft' failed during operation 'init' and will be disabled
java.lang.RuntimeException: java.lang.ClassNotFoundException: gcewing.sg.SGBaseTE
at com.google.common.base.Throwables.propagate(Throwables.java:160)
at openperipheral.util.ReflectionHelper.getClass(ReflectionHelper.java:128)
at openperipheral.integration.sgcraft.AdapterStargate.<init>(AdapterStargate.java:11)
at openperipheral.integration.sgcraft.ModuleSgCraft.init(ModuleSgCraft.java:21)
at openperipheral.IntegrationModuleRegistry$1.visit(IntegrationModuleRegistry.java:64)
at openperipheral.IntegrationModuleRegistry.visitModules(IntegrationModuleRegistry.java:52)
at openperipheral.IntegrationModuleRegistry.initAllModules(IntegrationModuleRegistry.java:61)
at openperipheral.OpenPeripheralCore.init(OpenPeripheralCore.java:47)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:545)
at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74)
at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45)
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313)
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296)
at com.google.common.eventbus.EventBus.post(EventBus.java:267)
at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:201)
at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:181)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74)
at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45)
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313)
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296)
at com.google.common.eventbus.EventBus.post(EventBus.java:267)
at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:112)
at cpw.mods.fml.common.Loader.initializeMods(Loader.java:699)
at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:249)
at net.minecraft.client.Minecraft.func_71384_a(Minecraft.java:509)
at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:808)
at net.minecraft.client.main.Main.main(SourceFile:101)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:131)
at net.minecraft.launchwrapper.Launch.main(Launch.java:27)
Caused by: java.lang.ClassNotFoundException: gcewing.sg.SGBaseTE
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:186)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at openperipheral.util.ReflectionHelper.getClass(ReflectionHelper.java:126)
... 42 more
Caused by: java.lang.NullPointerException
LanteaCraft is available here: http://www.minecraftforum.net/topic/2059956-
Resolved! It was an error on my part, forgot to parse the direction parameter as lower case.
If I try to call getTankInfo() for any tank-like object (BC tanks, RailCraft Iron Tank, RailCraft Coke Oven, etc) I get a table what contains only one string, net.minecraftforge.fluids.FluidTankInfo@7daef4ea
(the string after @ varies by query). It seems like return of a normal Java toString method, and really not a lua table, so I cannot call anything on it. It is a simple string object.
Exampel code:
tank = peripheral.wrap("back")
tinfo = tank.getTankInfo("unknown")[1]
The variable tinfo will contain string similar to my previous example.
I use:
This could allow for some more intuitive methods that can run off a default value to perform a common task, but can be changed by the developer. An example would be with getTankInfo
where you have the ForgeDirection optional and when it is not supplied it becomes unknown, then if they supply an argument it MUST be valid and does not default to unknown, this would help with #76.
This would mean that if a Turtle looks at a TE it may see some different methods than if a Computer looks at the same TE. A basic example would be with EnderTanks. A refuel
method could be exposed when a Turtle is reading it to allow it to refuel directly from the tank, but the Computer would not see the method.
This would add the ability for mods to specify to OpenPeripheral any TE's they wish to be ignored and not perform integration for. Then when ComputerCraft asks if we wish to handle the TE of course we check the blacklist and make sure that it is not present. Obviously we would also need to create a list of TE's that cannot be added so that it doesn't break all the things, like the TileEntity or any of our own TE's
Ability to return multiple values.
Tell me what you think.
โ BIT
The new recipe for the glasses requires ribbon cable, thin wire and coiled wire in the recipe. The NEI for coiled wire: 1 thin wire. The NEI for thin wire: 1 coiled wire, or ribbon cable makes 9. The NEI for ribbon cable: 9 thin wires.
Little bit of recursion going on here. No NEI for actually making the wire.
When using the getTanks method of the Buildcraft tanks, it considers the entire stack of tanks as one, meaning you get a total of the contents of the entire stack of tanks.
It does not do this for the OpenBlocks tank, which means you cannot (reliably) determine the contents for a OpenBlocks tank (especially if it's odd-shaped).
Latest build of each.
OpenPeripheral snapshot 86
BiblioCraft v1.5.2
Crash log : http://pastebin.com/3AYuxkPP
Full Log: http://pastebin.com/6dzSSkzj
I just loaded minecraft and it crashed, i wasn't doing anything.
Following on from ticket #105 which is now closed.
Documentation for openperipheral is now fully in-game, using "openp/docs [side]".
I think that would be worth mentioning on the website. Otherwise how are people going to know to run openp/docs
Aside from that, there is no documentation. Little point in documenting recipes and stuff these days as the majority of people use NEI or similar.
There's a lot more to documentation than just the recipes, especially for OpenBlocks which doesn't have the in-game documentation. If you don't want to maintain the docs yourself then how about linking to the github wikis from openmods.info homepage
I connected a computer to RC Iron Tank's Valve block, b/c this is the only case where I have getTankInfo() method. It returns with a table, but all standard TankInfo values (rawName, capacity, amount) are nil.
Used versions:
It would be very useful if Smeltery Controller can be handled as a tank too, not just an inventory. If it could be done, automation of smelting will be very easy as computer can query how much ingot (or how much mB of molten stuff) lays in the smeltery, and can calculate the casting process (to blocks/ingots). As I see on API side, MultiFluidTank supports getting FluidTankInfo's.
Nevermind, delete me.
The config file doesn't save after setting up block/item ID's, the result is that in 0.1.1, there is no easy way to set block/item ID's. To repro, simply start up Minecraft+OP with no config files- the config file that is generated for OP is empty.
When I insert items into the top slot of a packager with chest.pushItem(), the packager doesn't package the items. They just sit in the input slot. The same goes for packager.pullItem().
http://www.openperipheral.info/openperipheral/ is currently a 404. That is the URL which is linked from Mikeemoo's minecraft forum thread, https://github.com/OpenMods/OpenPeripheral, various modpack wikis, reddit threads and generally all over Google.
http://www.openperipheral.info/ doesn't seem to have any links to documentation for openperipheral or any of the open mods.
I have a computer next to a command block that runs a script when someone pushes a button. This works fine until i install OpenPeripheral. After installing OP, peripheral.getMethods returns nil for the command block.
Tried with MC 1.6.2, Forge 845, OP 0.2.1-snapshot-25
and MC 1.6.4, Forge 916, OP 0.2.1-forge9.11.0.883-snapshot-57
http://pastie.org/pastes/8094783/text
The XACT MPS module is also having this problem so I think something in MPS broke third party modules.
I have a suggestion: A door that can be rightklicked once by the person who placed it to set a password. This door is unbreakable and can only be mined by the player who placed it. It does neither respond to player's rightklick nor to redstone and can only be opened/closed by a computer. the peripheral should be then the block the door is placed on (it may not have any redstone or rightklick behaviour. like stone or wood) to not see the Computer. That block can be wrapped and then a command like p.identifyDoor("Password") to give that program access to the door. Then the door can be toggled via p.toggleDoor(boolean) while boolean is true for open, false for close or nil for just toggle from open to close or vice-versa
Moving this to a more permanent and public area than IRC so it can be easily discussed.
I propose that we split OpenPeripheral into two different packages:
OpenPeripheral should be part of the mod that converts blocks into peripherals. It should be pretty lightweight, easy to maintain..etc. I expect this to be the most active part. It should have no dependencies (except CC), and it should be able to be placed on a server without a client requirement.
The main reason for this is because I want to get a 1.6.x release out there, working, and with as little hassle as possible. When 1.7 hits, this mod should be very easily upgraded and released the moment that the new CC API comes out.
OpenPeripheral-Addons should be where terminal glasses, robots, PIM, remote and all that stuff goes. This stuff contains many bugs at the moment (lots of which I've forgotten about) and I can see releasing this stuff right now would be a massive ballache. I'm the person who knows my way around most of this, and I'm starting a new job soon, so the time I can devote to getting this ready quickly is very limited.
OpenPeripheral-Addons should require OpenPeripheral and OpenModsCore.
In theory, a stripped back OpenPeripheral could be released within days, and I'd really like to see it get released soon. Being able to just throw it onto a server is a huge benefit too.
I'd like to hear your thoughts, and please keep in mind that although I've reduced my participation in this mod over the past couple of months, we're still not near a releasable state.
With OpenPeripheral installed, I cannot get a command block to respond as a CC peripheral.
Using 0.2.1 preview 8, I can wrap a command block and get a table back, but the table has no keys, and doesn't have the typical command block commands (setCommand, etc). When using the latest build from Jenkins, snapshot 99, it doesn't even return a table when you wrap the command block, just returns nil.
If I remove OpenPeripheral altogether the command block wraps and functions fine. In all cases I have command blocks enabled in both the CC config and in server.properties.
AE (http://ae-mod.info/Dev/) added Spacial Pylons, that make add new dimension.
and ComputerCraft + OpenPeripheral are need for control Spatial IO Port.
I used Terminal Glasses for contol IO Port. and glasses are work on different dimension.
But i can't send command to comptuer. only screen update are happen.
(Remote also not work on different dimension. but i think that is not bug.)
http://www.youtube.com/watch?v=Y_8rnGfIVfs :D
Minecraft: 1.6.2
OpenPeripheral: OpenPeripheral-0.2.1-forge9.11.0.883-snapshot-57
Forge: 9.10.0.871
If you're running MCPC for your server the $$ commands sent in chat show up publicly. Under regular Forge server these are hidden.
If MCPC+ is considered unsupported, please feel free to remove.
crash on startup
http://www.minecraftforum.net/topic/2201440-opencomputers/
OpenComputer is Alternative ComputerCraft, it have presist option for chunk loading/unloading don't make reboot the computer. (and it use Lua!)
However, it have own api, it means when decided support the opencomputer, that will very hard work likely write new mod.
That is API, https://github.com/MightyPirates/OpenComputers/tree/master/li/cil/oc/api
isActive() seems to always return true, and getEUOutput() terminates the program.
http://pastebin.com/zyQAPK1G is the code I'm using to test. Whether the reactor has redstone going to it or not, it always gets to line 18, and never makes it to line 20.
I have no idea how to go about debugging this further, but am willing to try, if someone can point me in the right direction.
Edit: I suppose version info might help, though I don't see any tags or anything to match them to... Running DW20 V1.0.11 on Minecraft V1.6.4, with OpenPeripheral 0.2.1-preview8.
Edit 2: Picture of the setup, if that might help. http://i.imgur.com/efk4clx.png
^
Add back support for SGCraft for 1.6.x. SGCraft is now in 1.6.x as pointed out in the OpenP thread.
The credits added to the script cause an error: "=" expected.
A quick glance shows the second line is uncommented due to block comment missing a bracket.
This is a notice to inform people that I am changing the licence of this project to MIT. It is already open enough to be MIT compatible, the only change is I'm making the document actually readable and changing the attribution from Mikee Franklin to OpenMods Team.
Permission has been provided by Mikee to make this change.
The MIT License (MIT)
Copyright (c) 2013 OpenMods Team
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
You can check the liquid state (amount) of a simple tank fine, however, bigger tanks (2 or more tanks attached) only give out the information for the single tank attached to.
Is that possible to implement the full tank as information?
//EDIT: Idk how to add some label like enhancement :3
Thermal Expansion 3.0 has been released, but it is incompatible with the any version of MiscPeripherals by RichardG. It would be nice if OpenPeripherals added in Chunk Loader Turtles.
http://pastebin.com/wxzu81YZ (One Day Limit To See This Link; for security)
When i use the peripheral with Glasses + Miscperipheral's ChatBox.
Sometimes Server are stopped and does not print crash-report.
So i dumped the stack, heap for solve that problem
MiscPeripherals' version does not work with current Buildcraft.
Wrapped an Analyzer with analyzed bee in it, called and serialized getStackInSlot to get this response:
Sadly, no beeInfo table - what am I doing wrong?
Versions are Forestry-A-2.3.1.0 and OpenPeripheral-0.2.1-preview8 on Minecraft 1.6.4 (the current 1.0.11 version of the 1.6.4 incarnation of the Direwolf20 Feed the Beast mod pack).
Help finding the beeInfo table would be much appreciated, as I'm a bit of a noob.
Have API to parse soulshard items to get mobs killed, what mob and the type of mob
All accessable via NBT
It would be useful if tanks can be queryed to which amount of liquids contained inside. Technically it is possible, because IFluidTank exposes correspondent infos: https://github.com/MinecraftForge/MinecraftForge/blob/master/src/main/java/net/minecraftforge/fluids/IFluidTank.java but it requires access not only to IFluidHandler but an IFluidTank interface. too. I do not know it is possible or not.
I would be really happy if you would have the possibility to read the NBT data out of Item stacks. this would be useful for example for enchanted book. I tried it myself several times but i failed.
deathlymad
TE3's energycells methods such as getEnergyStored() require string parameter. It doesnt matter what the string contains, as an example it even works with "a", getEnergyStored("a")
I'm using latest dev openperipherals 0.2.1-snapshot-104
EDIT: Derped and realised those have to be in a form of "getEnergyStored", "string". Please just close this :D
When attempting to get the width of a text object it does not take account the text scale set on that object, resulting in large inaccuracies of calculations involving this method.
Code
local obj = glassBridge.addText(1, background.getY() + 5, calendar.getTime(), 0x000000)
obj.setScale(4)
obj.setX(background.getX() + (background.getWidth() - obj.getWidth()))
The above code (based on all the documentation I can find) should have the text positioned with the back of the text against the right side of the background colour. Instead it is positioned for a standard text scale. Default scale.
Hello,
first thanks for this great addon.
I currently have a small bug, the following program returns the turtle ID (only for the "basic" turtle), all the other turtle types returns nil.
Program:
local side = "top"
local t = peripheral.wrap(side)
print(t.getID())
Tested with:
Version MineCraft / Forge: 1.6.2 / 9.10.1.871
Version ComputerCraft: ComputerCraft1.56
Version OpenPeripheral: OpenPeripheral-0.2.1-forge9.11.0.883-snapshot-55
Version MiscPeripherals: miscperipherals-3.4b2 (Don't know if important)
greets sam
The following simple example returns 0 when trying to move a linking book from the turtle's inventory to a book receptacle located above the turtle. This worked in a previous version of Open Peripherals.
Placing a vanilla chest above the turtle and running the same commands gives the expected outcome (the book is moved from the turtle's inventory to the chest).
p = peripheral.wrap("top")
p.pullItem("down", 1, 1)
The following code example works with the book receptacle, however. (and is a valid workaround)
p = peripheral.wrap("top")
p.pullItemIntoSlot("down", 1, 1, 1)
SetColor seems to have some issues. It tends to make text gray, while I set it black.
Here's a snippet of my code:
function getNumber(peripheral, funct1, funct2, dec,tBox)
tBox.setText("Checking")
tBox.setColor(0xff0000)
if (net.isPresentRemote(peripheral)) then
no1 = net.callRemote(peripheral,funct1)
no2 = net.callRemote(peripheral,funct2)
perc = (no1 / no2) * 100
percRound = math.round(perc, dec)
if(percRound == "nan.00") then
tBox.setText("0%")
tBox.setColor(0xff0000)
else
tBox.setText(percRound .. "%")
tBox.setColor(0x000000)
end
else
tBox.setText("Error")
tBox.setColor(0xff0000)
end
end
With Forestry 2.3.1.0 and OpenPeripheral 0.2.1-snapshot99, I've noticed that the beeInfo tables (active and inactive) always show tolerantFlyer as being false. I've done some code diving and found it a little strange that the nocturnal and cave values are added like this:
active.put("caveDwelling", ((IAlleleBoolean)genome.getActiveAllele(EnumBeeChromosome.CAVE_DWELLING.ordinal())).getValue());
inactive.put("caveDwelling", ((IAlleleBoolean)genome.getInactiveAllele(EnumBeeChromosome.CAVE_DWELLING.ordinal())).getValue());
active.put("nocturnal", ((IAlleleBoolean)genome.getActiveAllele(EnumBeeChromosome.NOCTURNAL.ordinal())).getValue());
inactive.put("nocturnal", ((IAlleleBoolean)genome.getInactiveAllele(EnumBeeChromosome.NOCTURNAL.ordinal())).getValue());
And tolerantFlyer is done like this, with isDominant instead of getValue:
active.put("tolerantFlyer", genome.getActiveAllele(EnumBeeChromosome.TOLERANT_FLYER.ordinal()).isDominant());
inactive.put("tolerantFlyer", genome.getInactiveAllele(EnumBeeChromosome.TOLERANT_FLYER.ordinal()).isDominant());
I know this isn't a recent version of OpenPeripheral, but it also looks like this code hasn't changed.
Essentially an advanced computer that can only be broken by the person who placed it.
Providing an invalid side should not default to unknown, the correct operation would be to throw an exception/error stating that we require a side. Listing the available options.
Defaulting to anything when it's clear the end user has no idea what they're typing only makes the issue worse.
I use rv14.alpha2 of AE and for me, the ME Buses don't have any special methods, but the Controller has them.
Also the TicketMachine also has only Inventory Methods so it can't create Tickets.
the OpenPeripherals Version is 0.2.1 preview8.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.