Giter Club home page Giter Club logo

metalrenegades's Introduction

Metal Renegades

This is a module for Terasology. It provides a gameplay mode for a harsh western world with a robotic twist.

The robots of Metal Renegades

Contributing

We welcome contributions to our modules, be it bug fixes or feature contributions. Check out the Contributor Guide on the main project wiki to learn more.

To check out this module (and all its dependencies) to your Terasology workspace run (in the workspace root):

groovyw module recurse MetalRenegades

To build a module JAR for just this module run (in the workspace root):

gradlew :module:MetalRenegades:jar

To run all tests and static code checks for this module run (in the workspace root):

gradlew :module:MetalRenegades:check

Documentation via gh-pages

The documentation of this module is build with docsify. It is served via gh-pages. To preview the site you can either use the docsify CLI tool or just run a static server on the docs folder.

metalrenegades's People

Contributors

4denthusiast avatar adrijaned avatar agent-q1 avatar andytechguy avatar askneller avatar casals avatar cervator avatar darkweird avatar godfather2 avatar iaronaraujo avatar jdrueckert avatar keturn avatar mayant15 avatar naalit avatar pollend avatar qwertygiy avatar skaldarnar avatar spookynutz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

metalrenegades's Issues

Drink Capacity Tag of Wells misplaced

Wells are one of the buildings generated in a city in Metal Renegades.
They have a tag indicating how much water is still left in them.
Some recent change in our code base seems to have had some negative impact on that tag in the sense that it's no longer placed in the center of the well right above the water but diagonally from that next to / in one of the well roof posts:
Terasology-220424214940-2560x1387

I don't think that just changing the placement logic of the tag is a reasonable fix here, as the placement changed without the code being changed, so we'd be fixing symptoms only. Ideally, we should find out, why the placement is wrong now without the code being changed aka which other part of our code base (likely something in engine) was changed to this effect and fix that.

Crash on adding `DynamicWorld` generator in AGS for Metal Renegades

Terasology crashed when I tried to add the DynamicWorld generator in advanced game setup for Metal Renegades. It's coming from the FloraFeatureGenerato in GrowingFlora: https://github.com/Terasology/GrowingFlora/blob/develop/src/main/java/org/terasology/gf/generator/FloraFeatureGenerator.java#L58

I assume that before loading the game, WorldGeneratorPluginLibrary is not yet registered in the CoreRegistry which is why CoreRegistry.get(WorldGeneratorPluginLibrary.class) returns null.

Stacktrace:

java.lang.NullPointerException: null
	at org.terasology.gf.generator.FloraFeatureGenerator.loadPlantGrowthDefinitions(FloraFeatureGenerator.java:58)
	at org.terasology.gf.generator.FloraFeatureGenerator.<init>(FloraFeatureGenerator.java:45)
	at org.terasology.metalrenegades.world.dynamic.DynamicWorldGenerator.createWorld(DynamicWorldGenerator.java:73)
	at org.terasology.engine.world.generation.BaseFacetedWorldGenerator.getWorldBuilder(BaseFacetedWorldGenerator.java:94)
	at org.terasology.engine.world.generation.BaseFacetedWorldGenerator.getConfigurator(BaseFacetedWorldGenerator.java:74)
	at org.terasology.engine.rendering.nui.layers.mainMenu.WorldSetupScreen.configureProperties(WorldSetupScreen.java:162)
	at org.terasology.engine.rendering.nui.layers.mainMenu.WorldSetupScreen.setWorld(WorldSetupScreen.java:146)
	at org.terasology.engine.rendering.nui.layers.mainMenu.UniverseSetupScreen.lambda$initialise$1(UniverseSetupScreen.java:173)
	at org.terasology.nui.ActivatableWidget.activateWidget(ActivatableWidget.java:46)
	at org.terasology.nui.widgets.UIButton.activateWidget(UIButton.java:203)
	at org.terasology.nui.widgets.UIButton$1.onMouseRelease(UIButton.java:94)
	at org.terasology.nui.canvas.CanvasImpl.processMouseRelease(CanvasImpl.java:266)
	at org.terasology.engine.rendering.nui.internal.NUIManagerInternal.mouseButtonEvent(NUIManagerInternal.java:680)
	at org.terasology.engine.rendering.nui.internal.NUIManagerInternalMethodAccess.invoke(Unknown Source)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:379)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.sendConsumableEvent(EventSystemImpl.java:254)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:233)
	at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
	at org.terasology.engine.network.NetworkEventSystemDecorator.send(NetworkEventSystemDecorator.java:54)
	at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
	at org.terasology.engine.recording.RecordingEventSystemDecorator.send(RecordingEventSystemDecorator.java:34)
	at org.terasology.engine.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:190)
	at org.terasology.engine.input.InputSystem.send(InputSystem.java:524)
	at org.terasology.engine.input.InputSystem.sendMouseEvent(InputSystem.java:496)
	at org.terasology.engine.input.InputSystem.processMouseButtonInput(InputSystem.java:216)
	at org.terasology.engine.input.InputSystem.processMouseInput(InputSystem.java:195)
	at org.terasology.engine.input.InputSystem.update(InputSystem.java:130)
	at org.terasology.engine.core.modes.StateMainMenu.handleInput(StateMainMenu.java:133)
	at org.terasology.engine.core.subsystem.lwjgl.LwjglInput.postUpdate(LwjglInput.java:39)
	at org.terasology.engine.core.TerasologyEngine.tick(TerasologyEngine.java:509)
	at org.terasology.engine.core.TerasologyEngine.mainLoop(TerasologyEngine.java:460)
	at org.terasology.engine.core.TerasologyEngine.runMain(TerasologyEngine.java:436)
	at org.terasology.engine.core.TerasologyEngine.run(TerasologyEngine.java:402)
	at org.terasology.engine.Terasology.call(Terasology.java:207)
	at org.terasology.engine.Terasology.call(Terasology.java:70)
	at picocli.CommandLine.executeUserObject(CommandLine.java:1933)
	at picocli.CommandLine.access$1200(CommandLine.java:145)
	at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2332)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2326)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2291)
	at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2159)
	at picocli.CommandLine.execute(CommandLine.java:2058)
	at org.terasology.engine.Terasology.main(Terasology.java:139)

Citizen Asset References in Code

When replacing the placeholder gooey models for bad and good citizens, I added the respective assets named [bad|good]Robot and removed the old [bad|good]Citizen assets. While the prefabs could be spawned perfectly well with spawnPrefab [bad|good]Robot, the citizen spawning mechanism in the MetalRenegades cities and the Minimap didn't work. Assumedly it still tried to use the citizen assets instead of the new robot assets.

I found mentions in FactionAlignmentSystem.java:48 and CharacterOverlay.java:62, but adjusting these to the robot asset names didn't help either. So, this seems to be referenced somewhere in the MR code in a way that is not easy to find with grep or similar tools.

As a result, I created #110 and renamed all assets to the citizen variant again which fixed things. But this kind of hard-coded reference should be removed as it complicates any changes in that area very much.

Non-fatal stackoverflow on viewing the market UI

Saw this simply by opening the market screen on a gooey in a market place. The stackoverflow didn't seem fatal and the buttons just kinda kept vibrating in place. I think I had previously resized my window so maybe it only happens on some sizes? Relevant bit of my config + stacktrace:

    "windowPosX": 110,
    "windowPosY": 133,
    "windowWidth": 1362,
    "windowHeight": 892,
09:47:29.701 [main] ERROR o.t.e.event.internal.EventSystemImpl - Failed to invoke event
java.lang.NullPointerException: null
	at org.terasology.input.InputSystem.getInputsForBindButton(InputSystem.java:564)
	at org.terasology.dialogs.DialogSystem.createTalkText(DialogSystem.java:190)
	at org.terasology.dialogs.DialogSystem.updateTalkNotification(DialogSystem.java:99)
	at org.terasology.dialogs.DialogSystem.onTarget(DialogSystem.java:88)
	at org.terasology.dialogs.DialogSystemMethodAccess.invoke(Unknown Source)
	at org.terasology.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:532)
	at org.terasology.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:292)
	at org.terasology.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:283)
	at org.terasology.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:205)
	at org.terasology.input.cameraTarget.PlayerTargetSystem.update(PlayerTargetSystem.java:88)
	at org.terasology.engine.modes.StateIngame.update(StateIngame.java:171)
	at org.terasology.engine.TerasologyEngine.tick(TerasologyEngine.java:479)
	at org.terasology.engine.TerasologyEngine.mainLoop(TerasologyEngine.java:442)
	at org.terasology.engine.TerasologyEngine.run(TerasologyEngine.java:418)
	at org.terasology.engine.Terasology.main(Terasology.java:174)
09:47:29.701 [main] ERROR o.t.n.l.relative.RelativeLayout - Stack Overflow detected resolving layout of element responseButtons, unable to render
09:47:30.119 [main] ERROR o.t.n.l.relative.RelativeLayout - Stack Overflow detected resolving layout of element responseButtons, unable to render
...

Crash during Settlement Generation

Playing MetalRenegades in Singleplayer. Just travelled around the world, no interaction whatsoever. Then the game suddenly crashed:

java.lang.NullPointerException: Cannot read field "builtUpRadius" because "parcels" is null
	at org.terasology.dynamicCities.settlements.SettlementEntityManager.checkOutsideAllSettlements(SettlementEntityManager.java:262)
	at org.terasology.metalrenegades.combat.system.AnimalSpawnSystem.isValidSpawnPosition(AnimalSpawnSystem.java:52)
	at org.terasology.wildAnimals.system.WildAnimalsSpawnSystem.findFlockAnimalSpawnPositions(WildAnimalsSpawnSystem.java:161)
	at org.terasology.wildAnimals.system.WildAnimalsSpawnSystem.tryFlockAnimalSpawn(WildAnimalsSpawnSystem.java:127)
	at org.terasology.wildAnimals.system.WildAnimalsSpawnSystem.onChunkGenerated(WildAnimalsSpawnSystem.java:117)
	at org.terasology.wildAnimals.system.WildAnimalsSpawnSystemMethodAccess.invoke(Unknown Source)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:399)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:264)
	at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:255)
	at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
	at org.terasology.engine.network.NetworkEventSystemDecorator.send(NetworkEventSystemDecorator.java:54)
	at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
	at org.terasology.engine.recording.RecordingEventSystemDecorator.send(RecordingEventSystemDecorator.java:32)
	at org.terasology.engine.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:188)
	at org.terasology.engine.world.chunks.localChunkProvider.LocalChunkProvider.processReadyChunk(LocalChunkProvider.java:213)
	at org.terasology.engine.world.chunks.localChunkProvider.LocalChunkProvider.update(LocalChunkProvider.java:239)
	at org.terasology.engine.rendering.world.RenderableWorldImpl.update(RenderableWorldImpl.java:176)
	at org.terasology.engine.rendering.world.WorldRendererImpl.preRenderUpdate(WorldRendererImpl.java:285)
	at org.terasology.engine.rendering.world.WorldRendererImpl.render(WorldRendererImpl.java:325)
	at org.terasology.engine.core.modes.StateIngame.render(StateIngame.java:222)
	at org.terasology.engine.core.subsystem.lwjgl.LwjglGraphics.postUpdate(LwjglGraphics.java:79)
	at org.terasology.engine.core.TerasologyEngine.tick(TerasologyEngine.java:522)
	at org.terasology.engine.core.TerasologyEngine.mainLoop(TerasologyEngine.java:473)
	at org.terasology.engine.core.TerasologyEngine.runMain(TerasologyEngine.java:449)
	at org.terasology.engine.core.TerasologyEngine.run(TerasologyEngine.java:415)
	at org.terasology.engine.Terasology.call(Terasology.java:189)
	at org.terasology.engine.Terasology.call(Terasology.java:69)
	at picocli.CommandLine.executeUserObject(CommandLine.java:1933)
	at picocli.CommandLine.access$1200(CommandLine.java:145)
	at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2332)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2326)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2291)
	at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2159)
	at picocli.CommandLine.execute(CommandLine.java:2058)

Rail placement seems able to break a chunk generator thread

At least that's my interpretation of the log + game conditions where I've been able to both find single broken chunks and completely stalled chunk generation. Not entirely sure what the symptom would be here as I accidentally closed the game before inspecting the area. Log only seems to indicate a single chunk generation thread dying though, to an index out of bounds exception:

...
21:04:37.197 [main] WARN  o.t.l.nameTags.PlayerNameTagSystem - Can't create player based name tag for character as owner has no client component
21:04:39.530 [main] ERROR o.t.e.e.internal.PojoEntityManager - Adding a component (class org.terasology.network.NetworkComponent) over an existing component for entity 2539
21:04:39.644 [main] ERROR o.t.e.event.internal.EventSystemImpl - Failed to invoke event
java.lang.ArrayIndexOutOfBoundsException: -3839
        at gnu.trove.map.hash.TLongObjectHashMap.rehash(TLongObjectHashMap.java:165)
        at gnu.trove.impl.hash.THash.postInsertHook(THash.java:388)
        at gnu.trove.map.hash.TLongObjectHashMap.doPut(TLongObjectHashMap.java:248)
        at gnu.trove.map.hash.TLongObjectHashMap.put(TLongObjectHashMap.java:222)
        at org.terasology.entitySystem.entity.internal.ComponentTable.put(ComponentTable.java:52)
        at org.terasology.entitySystem.entity.EntityBuilder.lambda$build$0(EntityBuilder.java:111)
        at java.util.HashMap$Values.forEach(HashMap.java:980)
        at org.terasology.entitySystem.entity.EntityBuilder.build(EntityBuilder.java:111)
        at org.terasology.entitySystem.entity.EntityBuilder.buildWithoutLifecycleEvents(EntityBuilder.java:135)
        at org.terasology.world.internal.EntityAwareWorldProvider.createBlockEntity(EntityAwareWorldProvider.java:394)
        at org.terasology.world.internal.EntityAwareWorldProvider.getBlockEntityAt(EntityAwareWorldProvider.java:273)
        at org.terasology.minecarts.blocks.RailsBlockFamilyUpdateSystem.processUpdateForBlockLocation(RailsBlockFamilyUpdateSystem.java:150)
        at org.terasology.minecarts.blocks.RailsBlockFamilyUpdateSystem.blockUpdate(RailsBlockFamilyUpdateSystem.java:139)
        at org.terasology.minecarts.blocks.RailsBlockFamilyUpdateSystemMethodAccess.invoke(Unknown Source)
        at org.terasology.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:531)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:292)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:283)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:205)
        at org.terasology.world.internal.EntityAwareWorldProvider.updateBlockEntity(EntityAwareWorldProvider.java:202)
        at org.terasology.world.internal.EntityAwareWorldProvider.setBlock(EntityAwareWorldProvider.java:133)
        at org.terasology.world.internal.EntityAwareWorldProvider.setBlock(EntityAwareWorldProvider.java:120)
        at org.terasology.world.internal.WorldProviderWrapper.setBlock(WorldProviderWrapper.java:67)
        at org.terasology.dynamicCities.construction.Construction.onSetBlockEvent(Construction.java:679)
        at org.terasology.dynamicCities.construction.ConstructionMethodAccess.invoke(Unknown Source)
        at org.terasology.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:531)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.sendConsumableEvent(EventSystemImpl.java:302)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:281)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:205)
        at org.terasology.dynamicCities.construction.Construction.flatten(Construction.java:302)
        at org.terasology.dynamicCities.construction.Construction.flatten(Construction.java:318)
        at org.terasology.dynamicCities.construction.Construction.buildParcel(Construction.java:385)
        at org.terasology.dynamicCities.settlements.SettlementEntityManager.build(SettlementEntityManager.java:419)
        at org.terasology.dynamicCities.settlements.SettlementEntityManager.onWorldTimeEvent(SettlementEntityManager.java:172)
        at org.terasology.dynamicCities.settlements.SettlementEntityManagerMethodAccess.invoke(Unknown Source)
        at org.terasology.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:531)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:292)
        at org.terasology.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:283)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:205)
        at org.terasology.world.time.WorldTimeImpl.update(WorldTimeImpl.java:86)
        at org.terasology.engine.modes.StateIngame.update(StateIngame.java:171)
        at org.terasology.engine.TerasologyEngine.tick(TerasologyEngine.java:470)
        at org.terasology.engine.TerasologyEngine.mainLoop(TerasologyEngine.java:433)
        at org.terasology.engine.TerasologyEngine.run(TerasologyEngine.java:409)
        at org.terasology.engine.Terasology.main(Terasology.java:174)
21:04:39.646 [Chunk-Processing-Reactor] ERROR o.t.w.c.p.ChunkProcessingPipeline - ChunkTask at position (-1.600E+1  0.000E+0  1.500E+1) and stage [Chunk ready] catch error:
java.util.concurrent.ExecutionException: java.lang.ArrayIndexOutOfBoundsException: -1
        at java.util.concurrent.FutureTask.report(FutureTask.java:122)
        at java.util.concurrent.FutureTask.get(FutureTask.java:192)
        at org.terasology.world.chunks.pipeline.PositionFuture.get(PositionFuture.java:49)
        at org.terasology.world.chunks.pipeline.ChunkProcessingPipeline.onStageDone(ChunkProcessingPipeline.java:121)
        at org.terasology.world.chunks.pipeline.ChunkProcessingPipeline.chunkTaskHandler(ChunkProcessingPipeline.java:108)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
        at gnu.trove.map.hash.TLongObjectHashMap.rehash(TLongObjectHashMap.java:165)
        at gnu.trove.impl.hash.THash.postInsertHook(THash.java:388)
        at gnu.trove.map.hash.TLongObjectHashMap.doPut(TLongObjectHashMap.java:248)
        at gnu.trove.map.hash.TLongObjectHashMap.put(TLongObjectHashMap.java:222)
        at org.terasology.entitySystem.entity.internal.ComponentTable.put(ComponentTable.java:52)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.lambda$addComponent$8(PojoEntityManager.java:553)
        at java.util.Optional.map(Optional.java:215)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.addComponent(PojoEntityManager.java:553)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.addComponent(BaseEntityRef.java:168)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.getEntityInfo(BaseEntityRef.java:261)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.isPersistent(BaseEntityRef.java:52)
        at org.terasology.persistence.internal.EntitySetDeltaRecorder.onEntityComponentAdded(EntitySetDeltaRecorder.java:60)
        at org.terasology.persistence.internal.ReadWriteStorageManager.onEntityComponentAdded(ReadWriteStorageManager.java:514)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.notifyComponentAdded(PojoEntityManager.java:726)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.addComponent(PojoEntityManager.java:557)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.addComponent(BaseEntityRef.java:168)
        at org.terasology.world.chunks.localChunkProvider.LocalChunkProvider.generateQueuedEntities(LocalChunkProvider.java:260)
        at java.util.ArrayList.forEach(ArrayList.java:1249)
        at java.util.Collections$UnmodifiableCollection.forEach(Collections.java:1080)
        at org.terasology.world.chunks.localChunkProvider.LocalChunkProvider.processReadyChunk(LocalChunkProvider.java:231)
        at org.terasology.world.chunks.pipeline.stages.ChunkTaskProvider.lambda$null$1(ChunkTaskProvider.java:41)
        at org.terasology.world.chunks.pipeline.stages.SingleChunkTask.apply(SingleChunkTask.java:44)
        at org.terasology.world.chunks.pipeline.stages.SingleChunkTask.apply(SingleChunkTask.java:17)
        at org.terasology.world.chunks.pipeline.ChunkProcessingPipeline.lambda$runTask$4(ChunkProcessingPipeline.java:180)
        at org.terasology.world.chunks.pipeline.ChunkProcessingPipeline$PositionalCallable.call(ChunkProcessingPipeline.java:320)
        at org.terasology.world.chunks.pipeline.ChunkProcessingPipeline$PositionalCallable.call(ChunkProcessingPipeline.java:305)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at org.terasology.world.chunks.pipeline.PositionFuture.run(PositionFuture.java:29)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        ... 1 common frames omitted
21:04:42.421 [main] WARN  o.t.l.nameTags.PlayerNameTagSystem - Can't create player based name tag for character as owner has no client component
...

AI Integrations with Minimap System

Terasology/Minimap is currently integrated into Metal Renegades, but is currently only used in two places: to indicate different building regions from DynamicCities, and to indicate the position of settlements.

The minimap system should be expanded to include more information from Metal Renegades. This can include the positions of AI characters, market characters, water sources, food sources, with different symbols for each. They can be implemented in a similar way to Terasology/DynamicCities#42,

  • AI Characters #47
  • Market Characters #47
  • Water Sources
  • Food Sources

Characters stuck inside wells

#11 adds a new well building, where the gooey characters can fulfill their thirst need. This well has a one block wide hole that spans two blocks down, which is filled with water. This hole is unfortunately citizen-shaped, and they fall in when travelling to this source:

Terasology-190806165833-1920x1080
A citizen in a sticky situation

They continue to be stuck until travelling to another location, the stray behavior doesn't seem to allow them to jump out of the hole, but the follow behavior does.

This could potentially be solved in a few ways:

  1. Change the travel behavior, where characters don't need to travel to the exact centre of the source. (Probably the best solution)
  2. Make the water more shallow so the character can easily jump out.
  3. Make the character collisions larger than a 1x1 hole, so they cannot fall in.

Crash on selling item to Market Gooey

Playing MetalRenegades in Singleplayer. Tried to sell an item I found in an earlier session to the market gooey of a city I also found in that earlier session. Game crashed when hitting the "Sell" button.

21:57:58.944 [main] ERROR o.t.engine.core.TerasologyEngine - Uncaught exception, attempting clean game shutdown
java.lang.NullPointerException: null
        at org.terasology.metalrenegades.economy.systems.MarketManagementSystem.sell(MarketManagementSystem.java:195)
        at org.terasology.metalrenegades.economy.systems.MarketManagementSystem.onMarketTransactionRequest(MarketManagementSystem.java:160)
        at org.terasology.metalrenegades.economy.systems.MarketManagementSystemMethodAccess.invoke(Unknown Source)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:379)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:244)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:235)
        at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
        at org.terasology.engine.network.NetworkEventSystemDecorator.send(NetworkEventSystemDecorator.java:54)
        at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
        at org.terasology.engine.recording.RecordingEventSystemDecorator.send(RecordingEventSystemDecorator.java:34)
        at org.terasology.engine.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:190)
        at org.terasology.metalrenegades.economy.ui.MarketScreen.lambda$initialise$1(MarketScreen.java:128)
        at org.terasology.nui.ActivatableWidget.activateWidget(ActivatableWidget.java:46)
        at org.terasology.nui.widgets.UIButton.activateWidget(UIButton.java:203)
        at org.terasology.nui.widgets.UIButton$1.onMouseRelease(UIButton.java:94)
        at org.terasology.nui.canvas.CanvasImpl.processMouseRelease(CanvasImpl.java:266)
        at org.terasology.engine.rendering.nui.internal.NUIManagerInternal.mouseButtonEvent(NUIManagerInternal.java:680)
        at org.terasology.engine.rendering.nui.internal.NUIManagerInternalMethodAccess.invoke(Unknown Source)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:379)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.sendConsumableEvent(EventSystemImpl.java:254)
        at org.terasology.engine.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:233)
        at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
        at org.terasology.engine.network.NetworkEventSystemDecorator.send(NetworkEventSystemDecorator.java:54)
        at org.terasology.engine.core.bootstrap.eventSystem.AbstractEventSystemDecorator.send(AbstractEventSystemDecorator.java:67)
        at org.terasology.engine.recording.RecordingEventSystemDecorator.send(RecordingEventSystemDecorator.java:34)
        at org.terasology.engine.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:190)
        at org.terasology.engine.input.InputSystem.send(InputSystem.java:524)
        at org.terasology.engine.input.InputSystem.sendMouseEvent(InputSystem.java:496)
        at org.terasology.engine.input.InputSystem.processMouseButtonInput(InputSystem.java:216)
        at org.terasology.engine.input.InputSystem.processMouseInput(InputSystem.java:195)
        at org.terasology.engine.input.InputSystem.update(InputSystem.java:130)
        at org.terasology.engine.core.modes.StateIngame.handleInput(StateIngame.java:200)
        at org.terasology.engine.core.subsystem.lwjgl.LwjglInput.postUpdate(LwjglInput.java:39)
        at org.terasology.engine.core.TerasologyEngine.tick(TerasologyEngine.java:509)
        at org.terasology.engine.core.TerasologyEngine.mainLoop(TerasologyEngine.java:460)
        at org.terasology.engine.core.TerasologyEngine.runMain(TerasologyEngine.java:436)
        at org.terasology.engine.core.TerasologyEngine.run(TerasologyEngine.java:402)
        at org.terasology.engine.Terasology.call(Terasology.java:207)
        at org.terasology.engine.Terasology.call(Terasology.java:70)
        at picocli.CommandLine.executeUserObject(CommandLine.java:1933)
        at picocli.CommandLine.access$1200(CommandLine.java:145)
        at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2332)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2326)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2291)
        at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2159)
        at picocli.CommandLine.execute(CommandLine.java:2058)
        at org.terasology.engine.Terasology.main(Terasology.java:139)

Odd stackoverflow on market screen

Saw this simply by opening the market screen on a gooey in a market place. The stackoverflow didn't seem fatal and the buttons just kinda kept vibrating in place. I think I had previously resized my window so maybe it only happens on some sizes? Relevant bit of my config + stacktrace:

    "windowPosX": 110,
    "windowPosY": 133,
    "windowWidth": 1362,
    "windowHeight": 892,
09:47:29.701 [main] ERROR o.t.e.event.internal.EventSystemImpl - Failed to invoke event
java.lang.NullPointerException: null
	at org.terasology.input.InputSystem.getInputsForBindButton(InputSystem.java:564)
	at org.terasology.dialogs.DialogSystem.createTalkText(DialogSystem.java:190)
	at org.terasology.dialogs.DialogSystem.updateTalkNotification(DialogSystem.java:99)
	at org.terasology.dialogs.DialogSystem.onTarget(DialogSystem.java:88)
	at org.terasology.dialogs.DialogSystemMethodAccess.invoke(Unknown Source)
	at org.terasology.entitySystem.event.internal.EventSystemImpl$ByteCodeEventHandlerInfo.invoke(EventSystemImpl.java:532)
	at org.terasology.entitySystem.event.internal.EventSystemImpl.sendStandardEvent(EventSystemImpl.java:292)
	at org.terasology.entitySystem.event.internal.EventSystemImpl.send(EventSystemImpl.java:283)
	at org.terasology.entitySystem.entity.internal.BaseEntityRef.send(BaseEntityRef.java:205)
	at org.terasology.input.cameraTarget.PlayerTargetSystem.update(PlayerTargetSystem.java:88)
	at org.terasology.engine.modes.StateIngame.update(StateIngame.java:171)
	at org.terasology.engine.TerasologyEngine.tick(TerasologyEngine.java:479)
	at org.terasology.engine.TerasologyEngine.mainLoop(TerasologyEngine.java:442)
	at org.terasology.engine.TerasologyEngine.run(TerasologyEngine.java:418)
	at org.terasology.engine.Terasology.main(Terasology.java:174)
09:47:29.701 [main] ERROR o.t.n.l.relative.RelativeLayout - Stack Overflow detected resolving layout of element responseButtons, unable to render
09:47:30.119 [main] ERROR o.t.n.l.relative.RelativeLayout - Stack Overflow detected resolving layout of element responseButtons, unable to render
...

Using a pistol depletes ammo for all players

Shooting a bullet uses up a bullet for all players. The same entities are given to all players in the CombatStartingInventorySystem here

To Reproduce:

  • Host a game and join with a second client
  • Shoot the pistol on the host. The client's bullets are also used up

same_bullet

Add personal characteristics to each AI agent

With the factions system introduced in #36, each character in an individual city shares a common character model. This can make the citizens look rather plain in a group, therefore some distinguishing characteristics should be included in the spawn process, like below:

  • A name for each citizen, like what is already done for cities. #74
  • Variations in character size, easily done with the scale property inside the skeletalmesh of a character prefab. #74
  • Personality traits for each character which manipulate some behaviors, for example a lazy character would move slower, a greedy character would get hungry faster, etc.
  • Slight colour/tone variations between characters. Attempted as part of #74, didn't look good.

Dynamic Factions System for Players

Pull request #36 introduces a faction system to the game. When each in-game city is generated, it is assigned one faction from three possibilities: good, neutral, and bad.
image

Any character that spawn inside this city will also share the same faction, the entire city will be populated by this faction. When two characters from enemy factions come in contact with each other, (a good character and a bad character) they will run at each other and attack.

One more planned feature of this system that is not yet implemented is dynamic character factions. Just like every character is aligned with a particular faction, the player as well will have a faction alignment. However, this alignment will change over time, depending on actions that the player takes. For example, if the player spends time with, trades with, or takes quests for good characters, their faction alignment will shift towards the good side. Eventually, characters of the bad faction would begin attacking the player on sight.

Improvements for fetch quests

Beacon IDs and the Return Home Task

Because beaconIds are the same, if the same quest is taken multiple times, players don't need to go back to the beacon. Quests complete as soon as they collect items.

Minimap Overlay

The TaskOverlay is a minimap overlay which shows the player where they have to go for the return back task to be completed. Issue here is that the icon on the minimap is very far off from the actual location of the object in the real world.

Crash on trading with NPCs

while playing MR, if we interact (using E) with any citizen (like badCitizen), and click on Show me what you've got and after that select any item (eg. torches, dynamite etc.) then as soon as we click on Trade button, a NPE occurs

Steps to reproduce -

  1. Start game with MR template
  2. Interact with any NPC (using E)
  3. Click on Show me what you've got in the dialog window
  4. Select any item in the list
  5. Click on Trade and NPE will occur

e6

er.mp4

Reduce city growth rate

We may have to reduce city growth rate for more even gameplay. To do that, we'll have to first expose the counter in the SettlementEntityManager (located in Terasology/DynamicCities here) to other modules. We may use a setCityGrowthRate function in the SettlementEntityManager which is just a setter for counter and expose this function to MetalRenegades.

Full water cup can be filled from well

In Metal Renegades, water cups can be found or bought from citizens. These cups can be filled from wells in the cities to satisfy the player's need for water.
Wells have a default capacity of 5 "drinks" aka a water cup can be filled five times before the well needs to regenerate water resources (which takes a bit). Currently, it's possible to take another "drink" from the well even if the water cup is already full and will not take any more water.

IMO this is a design flaw that should be fixed to improve user experience and avoid nuisances such as accidentally reducing the well capacity more than intended resulting in water scarcity.

Crash on killing an animal

while killing an animal in MR using bow or staff (I only tested the two), a NPE occurs. This does not occur if we kill animal with stone pickaxe
To reproduce this -

  1. Start game with MR template
  2. Kill an animal using staff or bow and NPE will occur

e5

Items can be infinitely bought from Shopkeepers

When an item is bought from a Shopkeeper, it can continue to be bought even when there is no supply. This results in the amount of items flipping to negative in the shop:

image

To reproduce:

  1. Go up to a shopkeeper character (grey Gooey) and press 'e' to open up the shop dialog.
  2. Sell the shopkeeper an item from your inventory
  3. Buy it back from them multiple times, the supply will flip to a negative number.

This bug allows any item to be "duplicated", by selling it once and then buying it back infinitely (until the player's money supply runs out)

Clients cannot open the market dialog

To reproduce:

  • Host a game with the module active
  • Connect with a second client
  • Try to interact with the market citizen using the client, no dialog comes up

NPE for CurrencyManagementSystem in multiplayer

A pure client connected to a server running Metal Renegades appears to crash after a moment with the following error:

java.lang.NullPointerException
	at org.terasology.metalrenegades.economy.systems.CurrencyManagementSystem.update(CurrencyManagementSystem.java:43)
	at org.terasology.engine.modes.StateIngame.update(StateIngame.java:171)
	at org.terasology.engine.TerasologyEngine.tick(TerasologyEngine.java:458)
	at org.terasology.engine.TerasologyEngine.mainLoop(TerasologyEngine.java:421)
	at org.terasology.engine.TerasologyEngine.run(TerasologyEngine.java:397)
	at org.terasology.engine.Terasology.main(Terasology.java:156)

Am guessing the WalletSystem initialization isn't working for some reason on a pure client. It is fine on a server/client and the headless server itself is also fine.

Note that the idea of updating a player's wallet in a client system seems problematic, which may indeed be the problem - usually any sort of over-time simulation should happen in an authority system so it'll only run on the server.

In the same class: COOLDOWN could use a final thrown on there :-)

Well Nametags invisible to clients & reloaded players

The water wells inside a town are supposed to have a name tag attached to them, which show the number of drinks that the well can provide. This name tag appears properly when hosting the game at the time the well is generated. For any client or if the world is saved then loaded, then the name tag will disappear. Here is a visual comparison for multiplayer, the first showing the view of the game host, and the second showing the view of a client:

image
image

Pathfinding Issues

Whenever Characters need to go to the closest source to fulfill their needs, they can be seen jumping up and down against a wall.
Screenshot from 2020-03-30 02-00-59
This is probably an error with the pathFinding mechanism

Notify players when finding city

When finding a city, sometimes buildings take a while to be generated so the only indicator of having found a city is the city's name floating high above the player. This can easily be overlooked, so one idea would be to add a notification that pops up when a player finds a city.
For the time being, I can even imagine that it would be interesting for other players as well if a player found a city, so this information could be broadcast and the notification be created for every client.

For the notifications I'd recommend using the Notifications module.
For finding a suitable event to cause the notification to show up, I'd suggest looking in the DynamicCities and Cities modules for the respective code path or event that indicates the player having found a city. If there's no event yet, we should consider creating and using one.

`SkeletalMeshComponent: scale` renders new gltf models invisible

What you were trying to do

Chore: updating modules to work with new glTF assets

What actually happened

We noticed that when a creature prefab uses both a glTF model and the scale property from SkeletalMeshComponent, it becomes invisible in the game. Might be worth noting that scale is an instance of org.terasology.math.geom.Vector3f, so there might be a link with the latest JOML changes.

First observed at PR #101

How to reproduce

  • Step 1: Modify one of the citizen prefabs in MR by including the scale property in its component
  • Step 2: Spawn the citizen in-game and notice that it's invisible

Pathfinding Issues

Pathfinding Issues

Related to #29

What happens

The characters continuously request paths to the destination (as a result of their needs behaviours) almost flooding the system. However, the characters don't seem to have a direction for moving at all. They just sit idle.

Why it happens.

After investigation, the characters request for a path returns a successful path (The future is set to a valid result) however, the path always seems to have no WalkableBlocks in it's nodes. Hence, the characters have no path to actually follow along (in the move_along_path and move_to behaviours). The characters then keep requesting paths, possibly creating strain on the system. Maybe the NavgraphSystem is not tracking the blocks being added later by DC (example, while filling the floor before placing the house). Thus, whenever a path is requested, to the NavGraphSystem, it looks like the path is being requested from some point in the air. This point doesn't have any attached blocks to it (It's just a point hanging in the air). Thus, the NavGraphSystem is unable to return a valid path

How to fix

Improvements to the UdateChunk events and NavGraphChanged events.

Major performance hit when emptying city generation block buffer

To generate cities, DynamicCities first places all required blocks into a "block buffer". The blocks in this buffer are then placed on timed intervals. The process of placing blocks from this buffer creates a significant and very noticable performance delay. This process must be investigated and optimized.

image
Console output when block buffer is emptied

Mysterious BaseCitizen character spawning inside houses

When testing #47, a mysterious error message would fill up the console after a little bit of time in the game inside a city:
[main] ERROR o.t.m.minimap.CharacterOverlay - No icon found for citizenMetalRenegades:baseCitizen

An icon for the baseCitizen type of character doesn't exist in the overlay system, so an error is thrown every time the minimap has to display this type of overlay. These error messages are not the fault of the overlay system, but rather point to the existance of an untracked BaseCitizen character inside the world. I added an additional icon for this type of character (blue gooey), and these characters showed up in the middle of some residential houses:

image

If I looked in just the right spot, I could also see the tooltip of the character. This tooltip had a blank icon and no name:

image

These characters likely come from an error in the CitizenSpawnSystem, and could be a major memory leak in the game if left unchecked.

Icons not found for minimap usage

When playing normally I see a lot of this in the log:

21:39:13.677 [main] ERROR o.t.m.minimap.CharacterOverlay - No icon found for citizenMetalRenegades:gooeyCitizen
21:39:13.693 [main] ERROR o.t.m.minimap.CharacterOverlay - No icon found for citizenMetalRenegades:marketCitizen

The lack of space is a non issue, CharacterOverlay.render should have a space added for its log statement. There's probably a minor issue in fetching the icon assets correctly. Might be an easy fix! There are some minor-looking warnings in that method as well.

Maybe related: #111

Diversify the map with new biomes

MetalRenegades uses the default BiomeProvider, which takes surface height, temperature and humidity at a point and defines a biome at that point. As of now, the temperature and humidity is fixed at 0.6f and 0.1f respectively, here and here.

The goal is to change these hardcoded values to random values weighted in a way that the biome we get is mostly desert. Some ideas may be found in this StackOverflow thread

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.