Jump to content




[mc 1.6.x] Openperipheral


1184 replies to this topic

#541 Mikeemoo

  • Members
  • 732 posts
  • LocationLondon, UK

Posted 16 July 2013 - 07:13 AM

Righto, I'm marking preview8 as a beta now, with the view to release an official build within a couple of weeks.

I'm hoping a few more mods will release 1.6.x versions in that time!

#542 Yurij

  • Members
  • 18 posts

Posted 16 July 2013 - 08:32 AM

View PostMikeemoo, on 15 July 2013 - 04:15 PM, said:

https://dl.dropboxus....1-preview8.jar

Added/Fixed up all the Applied Energistics methods - all except requestCrafting, which I'm just kinda hoping is still working..

isFuzzyPreformatted()
getAvailableItems()
getAdvancedMethodsData()
getPreformattedItems()
getStoredItemCount()
getTotalBytes()
getUnusedItemCount()
getTotalItemTypes()
getFreeBytes()
isPreformatted()
listMethods()
containsItemType(temId, dmgValue)
countOfItemType(itemId, dmgValue)
getStoredItemTypes()
canHoldNewItem()
getPriority()
getRemainingItemTypes()
getName()
getUnusedBytes()
getRemainingItemCount()


Tested a couple of methods on a me chest with a preformated cell named Coal
  • isPreformatted() returns false
  • getName() return noting
  • getPriority() returns 1 while me chest was set to 1024
  • getPreformattedItems() returns nothing


#543 NOTUSEDPLEASEDELETE

  • Members
  • 70 posts

Posted 17 July 2013 - 02:15 AM

Great mod but I need a 1.4.7 version.

#544 Mikeemoo

  • Members
  • 732 posts
  • LocationLondon, UK

Posted 17 July 2013 - 04:47 AM

View PostFlick, on 17 July 2013 - 02:15 AM, said:

Great mod but I need a 1.4.7 version.

Nope, you need to update!

#545 SierraNine

  • Members
  • 9 posts

Posted 17 July 2013 - 09:34 AM

Love the mod, and LOVE the glasses...

I am getting differing names for items from an AE system through OpenPeripherals using getAvailableItems(), depending on SSP or SMP.

On both SSP and SMP, the rawname for each is appeng.materials.quartzcrystal and appeng.materials.quartzdust.

On SSP the names are Certus Quartz and Certus Quartz Dust respectively.

On SMP the names are AppEng.Materials.QuartzCrystal.name and AppEng.Materials.QuartzDust.name

Please note the case is different from the raw name on SMP.

Similar issues with ic2.blockOreTin and ic2.block.OreCopper, etc. Fine on SSP, not on SMP.

Minecraft 1.6.2
Forge 1.6.2-Forge9.10.0.789

AE rv11-e
OpenPeripherals 0.2.1 preview 8

Thanks in advance!

#546 Mikeemoo

  • Members
  • 732 posts
  • LocationLondon, UK

Posted 18 July 2013 - 12:38 PM



New idea I've been working on.

Not sure yet if this is going as a standalone mod or part of OpenPeripheral...

#547 Yurij

  • Members
  • 18 posts

Posted 18 July 2013 - 03:55 PM

View PostMikeemoo, on 18 July 2013 - 12:38 PM, said:



New idea I've been working on.

Not sure yet if this is going as a standalone mod or part of OpenPeripheral...

YES!!! This is awesome!!

#548 Thief^

  • Members
  • 29 posts

Posted 19 July 2013 - 07:47 AM

View PostFalesh, on 15 July 2013 - 02:17 PM, said:

This is an awesome mod!

One query, can you check how many of a specific item is stored an Applied Energistics network? I'm planning to keep certain items always in stock using "requestCrafting" but I haven't figured out how to check how much of a specific item is already in the network.

Can we get some new AE methods? getStoredItemCount(itemstack), getStoredItemTypes() (returning a table of itemstacks), getCraftableItemTypes() (returning a table of itemstacks), getPendingCraftingCount(itemStack) ?

I would also like to use OP to make AE automatically keep X of an item in stock, but without the ability to at least query how many of the item are stored and pending crafting I can't do this...

#549 Thief^

  • Members
  • 29 posts

Posted 19 July 2013 - 08:12 AM

It can be done manually, using an ME interface, precision export bus in crafting mode set to only work while not receiving a redstone signal, and a level emitter set to emit redstone at or above the level you want to keep the item at.

But a single computer to manage multiple items would be a lot smaller.

#550 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 July 2013 - 07:39 AM

Hey Mikeemoo,

Just curious, if possible is there any plans to be able to add the terminal glasses onto helmets, so we can still get our armour points but also be able to use the awesome features of the HUD?

— BIT

#551 Mikeemoo

  • Members
  • 732 posts
  • LocationLondon, UK

Posted 20 July 2013 - 08:53 AM

View Posttheoriginalbit, on 20 July 2013 - 07:39 AM, said:

Hey Mikeemoo,

Just curious, if possible is there any plans to be able to add the terminal glasses onto helmets, so we can still get our armour points but also be able to use the awesome features of the HUD?

— BIT

It's integrated with modular powersuits, so you can use that helmet.

I might consider adding it to vanilla helmets at some point :)

#552 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 July 2013 - 10:42 AM

View PostMikeemoo, on 20 July 2013 - 08:53 AM, said:

It's integrated with modular powersuits, so you can use that helmet.

I might consider adding it to vanilla helmets at some point :)
That one's banned on the server I'm on... damn... haha.
Any chance with a gravi? ;) xP

#553 DeweySalt

  • Members
  • 52 posts
  • LocationIn a galaxy far far away, aka New York

Posted 20 July 2013 - 03:00 PM

The terminal glasses are awesome! It'd be nice though if there was a getScreenHeight and getScreenWidth function so that I could orientate things to other parts of the screen rather than the top left. Also with the "chat_command" event, it'd be nice if it gave the player who issued the command.

#554 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 July 2013 - 03:26 PM

View PostDeweySalt, on 20 July 2013 - 03:00 PM, said:

It'd be nice though if there was a getScreenHeight and getScreenWidth function
This has been asked several times, each time being rejected as it is hard to do in a multiuser environment, since each user can have different screen sizes.

View PostDeweySalt, on 20 July 2013 - 03:00 PM, said:

Also with the "chat_command" event, it'd be nice if it gave the player who issued the command.
It does... http://puu.sh/3HAId.png

#555 GothicMage

  • Members
  • 6 posts

Posted 20 July 2013 - 05:57 PM

Show me that server has forbidden powerarmor instead of imbalanced GraviSuit Posted Image

#556 DeweySalt

  • Members
  • 52 posts
  • LocationIn a galaxy far far away, aka New York

Posted 20 July 2013 - 06:09 PM

View Posttheoriginalbit, on 20 July 2013 - 03:26 PM, said:

View PostDeweySalt, on 20 July 2013 - 03:00 PM, said:

It'd be nice though if there was a getScreenHeight and getScreenWidth function
This has been asked several times, each time being rejected as it is hard to do in a multiuser environment, since each user can have different screen sizes.

View PostDeweySalt, on 20 July 2013 - 03:00 PM, said:

Also with the "chat_command" event, it'd be nice if it gave the player who issued the command.
It does... http://puu.sh/3HAId.png

Ah, I understand, but would it still be possible to change the XY orientation to a certain corner of the screen?

And with the "chat_command" event sorry about that, I didn't think to look at all the params it gave.

#557 Engineer

  • Members
  • 1,378 posts
  • LocationThe Netherlands

Posted 20 July 2013 - 06:24 PM

View PostDeweySalt, on 20 July 2013 - 06:09 PM, said:

Ah, I understand, but would it still be possible to change the XY orientation to a certain corner of the screen?

Of course you can, the only thing is that it is hardcoded, because you dont know the width of the screen or anything. Top left is just because it is the most logical thing to do.

#558 DeweySalt

  • Members
  • 52 posts
  • LocationIn a galaxy far far away, aka New York

Posted 20 July 2013 - 10:45 PM

View PostEngineer, on 20 July 2013 - 06:24 PM, said:

View PostDeweySalt, on 20 July 2013 - 06:09 PM, said:

Ah, I understand, but would it still be possible to change the XY orientation to a certain corner of the screen?

Of course you can, the only thing is that it is hardcoded, because you dont know the width of the screen or anything. Top left is just because it is the most logical thing to do.

I was suggesting that it be added into the mod itself, like a changeOrientation() function, that'll change the XY orientation to a certain corner of the screen

#559 Wouto1997

  • Members
  • 15 posts

Posted 21 July 2013 - 10:48 AM

Here's what I did with it: (image too big, here's link)

and the script for it:

-- popup box color settings
popupdarkcolor = 0x0000AA
popuplightcolor = 0x5555FF
popupopacity1 = 0.5
popupopacity2 = 0.5
-- popup location
popupx = 10
popupy = 10
-- first word to check for, for adding a message
checkword = "addmsg"
-- text colors
namecolor = 0xFFFF55
nameshadowcolor = 0x3F3F15
messagecolor = 0xFFFFFF
messageshadowcolor = 0x3F3F3F
-- peripherals locations
chatboxlocation = "top"
glassesbridgelocation = "right"
rednetlocation = "left"

p = peripheral.wrap(glassesbridgelocation)
chat = peripheral.wrap(chatboxlocation)
rednet.open("left")
function split(pString, pPattern)
   local Table = {}  -- NOTE: use {n = 0} in Lua-5.0
   local fpat = "(.-)" .. pPattern
   local last_end = 1
   local s, e, cap = pString:find(fpat, 1)
   while s do
		  if s ~= 1 or cap ~= "" then
		  table.insert(Table,cap)
		  end
		  last_end = e+1
		  s, e, cap = pString:find(fpat, last_end)
   end
   if last_end <= #pString then
		  cap = pString:sub(last_end)
		  table.insert(Table, cap)
   end
   return Table
end

players = {}
msgs = {}
function checkMsg(msg)
  local checkvar = split(msg, " ")
  local taskmsg = ""
  if checkvar[1]==checkword then
    for i=2,#checkvar,1 do
	  taskmsg = taskmsg..checkvar[i].." "
    end
    return taskmsg
  end
  return false
end
function clear()
  p.clear()
end
function popup(x, y, width, height)
  local mbox = p.addGradientBox(x, y, width, height, popuplightcolor, popupopacity1, popupdarkcolor, popupopacity2, 2)
end
function getStringWidth(str)
  return p.getStringWidth(str)
end
p.clear()
while true do
  repeat
    event = {os.pullEvent()}
  until event[1]=="chat" or event[1]=="rednet_message"
  player = ""
  msg = ""
  if event[1]=="chat" then
    player = event[2]
    msg = event[3]
  elseif event[1]=="rednet_message" then
    player = "computer-"..event[2]
    msg = event[3]
  end
  p.clear()
  msg = checkMsg(msg)
  if not msg==false then
    msg = "   "..msg
    p.clear()
    player = " "..player..": "
    hasset = false
    for i=1,5,1 do
	  if msgs[i]==nil then
	   msgs[i]=msg
	   players[i]=player
	   hasset = true
	   break
	  end
    end
    if not hasset then
	  for i=2,5,1 do
	    msgs[i-1] = msgs[i]
	    players[i-1] = players[i]
	  end
	  msgs[5] = msg
	  players[5] = player
    end
    dw = 0
    for i=1,#players,1 do
	  if getStringWidth(players[i]) > dw then dw=getStringWidth(players[i]) end
	  if getStringWidth(msgs[i]) > dw then dw = getStringWidth(msgs[i]) end
    end
    dw = dw + 4
    dh = #msgs * 20
    dh = dh + 4
    popup(popupx, popupy, dw, dh)
    for i=1,#players,1 do
	  yoffset = 20*(i-1)
	  local shadowname = p.addText(13, yoffset+13, players[i], nameshadowcolor)
	  local name = p.addText(12, yoffset+12, players[i], namecolor)
	  local shadowmsg = p.addText(13, yoffset+23, msgs[i], messageshadowcolor)
	  local rmsg = p.addText(12, yoffset+22, msgs[i], messagecolor)
	  shadowname.setZIndex(1)
	  shadowmsg.setZIndex(1)
	  rmsg.setZIndex(2)
	  name.setZIndex(2)
    end
  end
end


#560 GothicMage

  • Members
  • 6 posts

Posted 21 July 2013 - 11:17 AM

OpenBlocks? What does that mean?





3 user(s) are reading this topic

0 members, 3 guests, 0 anonymous users