mirror of
https://github.com/teoxoy/factorio-blueprint-editor.git
synced 2025-01-18 02:58:31 +02:00
fixed bug where you could add more modules than the machine supported
This commit is contained in:
parent
37344bb1fa
commit
0fbb02f05d
@ -109,9 +109,11 @@ export class EditEntityContainer extends PIXI.Container {
|
||||
if (e.data.button === 0) {
|
||||
G.inventoryContainer.toggle(entity.acceptedModules, name => {
|
||||
G.openedGUIWindow = this
|
||||
if (modules && modules[i] !== name) {
|
||||
modules[modules.length] = name
|
||||
entity.modulesList = modules
|
||||
if (modules) {
|
||||
if (modules[i] !== name) {
|
||||
modules[modules[i] ? i : modules.length] = name
|
||||
entity.modulesList = modules
|
||||
}
|
||||
} else {
|
||||
entity.modulesList = [name]
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user