Jump to content




Peripheral not recognized as present


  • You cannot reply to this topic
5 replies to this topic

#1 Xtansia

  • Members
  • 492 posts
  • LocationNew Zealand

Posted 15 March 2012 - 09:18 AM

I'm just trying to test the peripheral api,
But with my current code the block isn't recognized as a peripheral.

mod_ :
Spoiler

Block :
Spoiler

TileEntity :
Spoiler


#2 Espen

    Curious Explorer

  • Members
  • 708 posts

Posted 15 March 2012 - 12:16 PM

I'm not using forge in my current workspace, so I don't know if that's why you use getTileEntity, but try to replace getTileEntity(int md) with getBlockEntity() in your Block file.

Edit: Oops, sorry forgot something. If you use getBlockEntity, then you have to extend BlockContainer instead of Block. :D/>

Edited by Espen, 15 March 2012 - 12:28 PM.


#3 Xfel

    Peripheral Designer

  • Members
  • 515 posts

Posted 15 March 2012 - 03:46 PM

You can't add tile entities for blocks which don't extend BlockContainer. So you need to subclass BlockContainer instead of Block.

#4 rockymc

  • Members
  • 103 posts

Posted 15 March 2012 - 04:57 PM

Note #1: Doesn't use Forge Sprites/Textures

#5 Xtansia

  • Members
  • 492 posts
  • LocationNew Zealand

Posted 16 March 2012 - 02:43 AM

Herp A Derp,
I knew it would be something simple like that,
Thanks Espen & Xfel

@rockymc
I have Forge Texture support in this,
I know how to use forge.

#6 Casper7526

    OG of CC

  • Members
  • 362 posts

Posted 16 March 2012 - 02:58 AM

Yep just change to extends BlockContainer and you should be fine.

BTW, if Anyone would like to make a VERY basic framework that uses forge sprite/textures feel free.





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users