You are not logged in.

IC2 Experimental builds (jenkins):
v2.0/2.1/2.2 / 2.3 / 2.5 / 2.6 (For Minecraft 1.6.4/1.7.2/1.7.10 / 1.8.9 / 1.9.4 / 1.10)
IndustrialCraft² recent version: v1.117! (For Minecraft 1.5.2 → topic)

Dear visitor, welcome to IC² Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Kotori

Tree Cutter

  • "Kotori" is male
  • "Kotori" started this thread
  • China

Posts: 10

Location: BUAA, Beijing, China

  • Send private message

1

Monday, March 20th 2017, 11:41am

failed to join an energy net when loading a world

i did a block using EU myself, but it was somewhere wrong:(
in the tileentity part of my block, i do what i did in 189 version(in fact, i copy&paste my code)(which worked very well in the older version)
but when i was trying to join a world, it went wrong because of a looped call.(when the block tried to join an energy net)
here's my code:https://github.com/Kanbe-Kotori/RailgunC…ftingTable.java

what's more, this block also has something wrong when rendering in the world... (although it seems to be my bad)


PS: maybe you dont know that there is too few people making mods now in my country. Thus, i have no way to ask for help without your forum(actually its also the only place i know)
i feel so sorry if my behavior(post a lot of threads) bothers you.
(i hope you can understand what im saying for my english level's too bad...)

Kotori

Tree Cutter

  • "Kotori" is male
  • "Kotori" started this thread
  • China

Posts: 10

Location: BUAA, Beijing, China

  • Send private message

2

Monday, March 20th 2017, 11:48am


although it can work in normal occasions...

Chocohead

Drowning in mods.

  • "Chocohead" is male
  • Korea, Democratic People's Republic of United Kingdom

Posts: 5,978

Location: Badly generated chunks.

  • Send private message

3

Monday, March 20th 2017, 4:18pm

it went wrong because of a looped call.(when the block tried to join an energy net
Do you have a crash report/log of this? The code itself looks ok, but onLoaded() should probably check if addedToEnergyNet is true before posting an energy load event.
this block also has something wrong when rendering in the world... (although it seems to be my bad)
That's from this line, you'll want to change it to

Source code

1
return EnumBlockRenderType.MODEL;
145 Mods isn't too many. 9 types of copper and 8 types of tin aren't too many. 3 types of coffee though?

I know that you believe that you understood what you think I said, but I am not sure you realise that what you read was not what I meant.


---- Minecraft Crash Report ----
// I just don't know what went wrong :(

I see this too much.

Kotori

Tree Cutter

  • "Kotori" is male
  • "Kotori" started this thread
  • China

Posts: 10

Location: BUAA, Beijing, China

  • Send private message

4

Monday, March 20th 2017, 5:27pm

the problem of rendering solved successfully. thx:)

however, the looped call problem is still unsolved:(

i know the meaning of what you said, but in fact i determine whether it's addedToEnergyNet in the function intialize() when i try to call onLoaded()

besides, there's no crashreport in my folder, for it doesn't crash anymore.

↓see this picture and you'll understand


(these lines) just loop and loop, and continuously making hundreds of lines of report before my memory is used out. that really makes me so sad.

Speiger

TMT & IC2 Classic Dev

  • "Speiger" is male

Posts: 996

Location: Germany

  • Send private message

5

Monday, March 20th 2017, 6:02pm

dont use validate function there is the TileEntity not added to the World yet...
use onLoad() the function is basicly called after the TileEntity is added to the chunk.
Best thing would be to add a even bigger delay and wait 1 tick to inject it.

This post by "Kotori" (Tuesday, March 21st 2017, 3:32am) has been deleted by the author himself (Tuesday, March 21st 2017, 4:29am)

Kotori

Tree Cutter

  • "Kotori" is male
  • "Kotori" started this thread
  • China

Posts: 10

Location: BUAA, Beijing, China

  • Send private message

7

Tuesday, March 21st 2017, 4:35am

dont use validate function there is the TileEntity not added to the World yet...
use onLoad() the function is basicly called after the TileEntity is added to the chunk.
Best thing would be to add a even bigger delay and wait 1 tick to inject it.
yep you're right. i moved the call of onLoaded() func from validate() to update(), and it finally solved.

thx a lot. :)

btw, your english grammar is not so similar to what i've learned:( and it took me a long time to realize your real meaning(and i even understood a wrong meaning for a time)(and dealt a wrong way to solve my problem)

GregoriusT

inactive IC² Dev but still active GT Dev

  • "GregoriusT" is male
  • Germany

Posts: 11,190

Location: Wherever I want to be (most of the time)

  • Send private message

8

Tuesday, March 21st 2017, 11:23am

Yes, we all sometimes have issues understanding Speiger, not everyone is good at englishing :P
I don't say, your "insert whatever here" is bad, I'm only showing possibilities for making it better.

GregTech Website

Patreon really helps me out, so if you consider funding the development of GT, so I might be able to do it full time, why not?

GregTech 6, the Main Thread, Bug Reports go here too.

I'm also reachable on #gt-dev on irc.esper.net, if you don't want to make a Forum account to contact me, for example. ;)
(I'm there almost every day, but only when I'm at my own computer, and yes you can drop bugs there too)

9

Tuesday, March 21st 2017, 4:17pm

Check out my mods here.

Counter:

Hits today: 42,545 | Hits yesterday: 42,089 | Hits record: 152,331 | Hits total: 65,051,943