Giter Club home page Giter Club logo

openperipheral's People

Contributors

blue42u avatar boq avatar chuesler avatar clienthax avatar crafteverywhere avatar cybcaoyibo avatar ds84182 avatar emberwalker avatar foone avatar gaeakat avatar koosemose avatar mikeemoo avatar nevercast avatar scottydelicious avatar sinz163 avatar spauldo avatar theoriginalbit avatar turakar avatar vexatos avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

openperipheral's Issues

Support for LanteaCraft

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-

Fluid tanks getTankInfo should return with a lua table instead of string

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:

  • MC 1.6.4
  • Forge Mod Loader version 6.4.20.939
  • BC 4.1.0
  • RailCraft 8.2.0.0

New OpenP API Ideas

Ability to specify optional arguments for methods.

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.

Ability to specify an argument should only be exposed for Turtles or Computers.

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.

Block/TileEntity BlackList

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

Removed

Ability to return multiple values.


Tell me what you think.

โ€” BIT

Can't make wire for glasses

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.

OpenBlocks tank

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).

Documentation for all OpenMods

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

RailCraft Iron Tank is not queriable

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:

  • MC 1.6.4
  • OpenPeripheral 0.2.1-forge9.11.0.898-snapshot-95
  • RailCraft 8.2.0.0

Make TConstruct smeltery controller to work as tank

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.

OP 0.1.1 - Config File does not save

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.

Packager ignores items from x.pushItem()

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().

Command Blocks not working with OpenPeripheral

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

Suggestion: Secure computer controlled doors

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

Core and Addons

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
  • OpenPeripheral-Addons

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.

Command Block peripherals broken

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.

chat_command event are not fired when Computer's Dim != Player's Dim

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

IC2 Reactors isActive() and getEUOutput() don't work

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

docs script doesn't run

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.

Licence change to MIT

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.

OpenBlocks Tank Support

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

Chunk loader turtle

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.

beeInfo table

Wrapped an Analyzer with analyzed bee in it, called and serialized getStackInSlot to get this response:

oyb2igc

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.

Better SoulShards API

Have API to parse soulshard items to get mobs killed, what mob and the type of mob

All accessable via NBT

enhancement NBT Reading

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 Methods require string parameter

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

getWidth on text object

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.

Screenshot

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.

Bug: Turtle Method .getID() - Returns Nil - For all non basic turtles

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:

  • Wireless Turtle
  • Wireless Mining Turtle
  • Wireless Felling Turtle
  • Farming Turtle
  • Crafty Mining Turtle

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

peripheral.pullItem doens't work with a Mystcraft book receptacle

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 not working properly

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

BeeInfo table always shows false for tolerantFlyer

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.

AE Buses and Ticket Machine don't wok

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.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.