Fix multiblock energy storage charging when reaching int.max #330

Merged
GotoFinal merged 1 commit from energy-fix into dev/1.20.1 2023-08-05 13:10:19 +00:00
GotoFinal commented 2023-07-22 19:05:32 +00:00 (Migrated from github.com)

Description

Small fix to make multiblock capacitor accept more than int.max energy.

Also small optimisation to code extracting/receiving energy - but I believe this code overall could use more love... But I don't personally use enderio much for it and it requires bigger work so not motivated myself...
Currently every operation on multiblock copies the data from graph, shuffles it, and iterates over all elements (well now not always all), this will make these multiblock structures to cause quite high load, especially when they are big and empty/full, as each operation will repeat every tick doing nothing.

Closes #302

Checklist:

  • My code follows the style guidelines of this project (.editorconfig, most IDEs will use this for you).
  • I have performed a self-review of my own code.
  • I have commented my code in areas it may be challenging to understand.
  • I have made corresponding changes to the documentation.
  • My changes are ready for review from a contributor.
# Description Small fix to make multiblock capacitor accept more than int.max energy. Also small optimisation to code extracting/receiving energy - but I believe this code overall could use more love... But I don't personally use enderio much for it and it requires bigger work so not motivated myself... Currently every operation on multiblock copies the data from graph, shuffles it, and iterates over all elements (well now not always all), this will make these multiblock structures to cause quite high load, especially when they are big and empty/full, as each operation will repeat every tick doing nothing. Closes #302 # Checklist: - [x] My code follows the style guidelines of this project (.editorconfig, most IDEs will use this for you). - [x] I have performed a self-review of my own code. - [x] I have commented my code in areas it may be challenging to understand. <!-- (Although we prefer code that is readable instead of over-commented) --> - [x] I have made corresponding changes to the documentation. - [x] My changes are ready for review from a contributor.
GotoFinal commented 2023-07-25 13:28:08 +00:00 (Migrated from github.com)

I'm a bit confused by the milestones now, the issue this PR fixes is in 6.0, yet the PR is in 6.1? @Rover656

I'm a bit confused by the milestones now, the issue this PR fixes is in 6.0, yet the PR is in 6.1? @Rover656
Rover656 commented 2023-07-25 13:29:00 +00:00 (Migrated from github.com)

Milestones are currently being shifted around, this one should probably continue to target 6.0, I'll fix this :) Cheers

Milestones are currently being shifted around, this one should probably continue to target 6.0, I'll fix this :) Cheers
Rover656 commented 2023-08-02 18:26:53 +00:00 (Migrated from github.com)

Just so you know; I'm not forgetting about this one either, I'd just like to let agnor decide if these changes make sense, as I didn't have any part in how this system works :)

Just so you know; I'm not forgetting about this one either, I'd just like to let agnor decide if these changes make sense, as I didn't have any part in how this system works :)
justliliandev (Migrated from github.com) approved these changes 2023-08-05 13:03:24 +00:00
justliliandev (Migrated from github.com) left a comment

works, I wanted to do some performance improvements for cap banks, but this is a good fix for the time being, thanks a lot

works, I wanted to do some performance improvements for cap banks, but this is a good fix for the time being, thanks a lot
Sign in to join this conversation.
No reviewers
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Team-EnderIO/EnderIO#330
No description provided.