GithubHelp home page GithubHelp logo

Comments (18)

jzvandenoever avatar jzvandenoever commented on August 11, 2024

This map crashes the server more consistently.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<newMap>
    <area>
        <x>70.0</x>
        <y>60.0</y>
    </area>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>22.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>22.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>27.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>27.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>22.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>27.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>22.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>27.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>42.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>47.5</x>
            <y>32.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>42.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>47.5</x>
            <y>37.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>42.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>42.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>32.5</x>
            <y>47.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <entities>
        <name>Bot</name>
        <position>
            <x>37.5</x>
            <y>47.5</y>
        </position>
        <type>NORMAL</type>
    </entities>
    <oneBotPerCorridorZone>false</oneBotPerCorridorZone>
    <randomBlocks>0</randomBlocks>
    <randomSequence>0</randomSequence>
    <sequence>RED</sequence>
    <sequence>RED</sequence>
    <sequence>YELLOW</sequence>
    <sequence>YELLOW</sequence>
    <sequence>BLUE</sequence>
    <sequence>BLUE</sequence>
    <zones>
        <blocks>WHITE</blocks>	
        <blocks>WHITE</blocks>	
        <blocks>WHITE</blocks>	
        <blocks>WHITE</blocks>		
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>35.0</x>
            <y>5.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>35.0</x>
                <y>10.0</y>
            </position>
        </doors>
        <name>RoomB2</name>
        <neighbours>CorridorD2</neighbours>
        <type>ROOM</type>
    </zones>    
    <zones>
        <blocks>RED</blocks>
        <blocks>RED</blocks>
        <blocks>YELLOW</blocks>
        <blocks>RED</blocks>
        <blocks>RED</blocks>
        <blocks>YELLOW</blocks>		
        <blocks>RED</blocks>
        <blocks>RED</blocks>
        <blocks>YELLOW</blocks>
        <blocks>RED</blocks>
        <blocks>RED</blocks>
        <blocks>YELLOW</blocks>			
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>25.0</x>
            <y>15.0</y>
        </boundingbox>
        <doors>
            <orientation>VERTICAL</orientation>
            <position>
                <x>30.0</x>
                <y>15.0</y>
            </position>
        </doors>
        <name>RoomB1</name>
        <neighbours>CorridorD2</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>35.0</x>
            <y>15.0</y>
        </boundingbox>
        <name>CorridorD2</name>
        <neighbours>RoomB2</neighbours>
        <neighbours>RoomB1</neighbours>
        <neighbours>StartZoneD3</neighbours>
        <neighbours>RoomB3</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <blocks>YELLOW</blocks>
		<blocks>BLUE</blocks>		
		<blocks>BLUE</blocks>		
        <blocks>YELLOW</blocks>
		<blocks>BLUE</blocks>		
		<blocks>BLUE</blocks>			
        <blocks>YELLOW</blocks>
		<blocks>BLUE</blocks>		
		<blocks>BLUE</blocks>		
        <blocks>YELLOW</blocks>
		<blocks>BLUE</blocks>		
		<blocks>BLUE</blocks>			
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>45.0</x>
            <y>15.0</y>
        </boundingbox>
        <doors>
            <orientation>VERTICAL</orientation>
            <position>
                <x>40.0</x>
                <y>15.0</y>
            </position>
        </doors>
        <name>RoomB3</name>
        <neighbours>CorridorD2</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>15.0</x>
            <y>25.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>15.0</x>
                <y>30.0</y>
            </position>
        </doors>
        <name>RoomA3</name>
        <neighbours>CorridorB4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>25.0</x>
            <y>25.0</y>
        </boundingbox>
        <name>CorridorC3</name>
        <neighbours>StartZoneC4</neighbours>
        <neighbours>StartZoneD3</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>35.0</x>
            <y>25.0</y>
        </boundingbox>
        <name>StartZoneD3</name>
        <neighbours>CorridorD2</neighbours>
        <neighbours>CorridorC3</neighbours>
        <neighbours>StartZoneD4</neighbours>
        <neighbours>CorridorE3</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>45.0</x>
            <y>25.0</y>
        </boundingbox>
        <name>CorridorE3</name>
        <neighbours>StartZoneD3</neighbours>
        <neighbours>StartZoneE4</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>55.0</x>
            <y>25.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>55.0</x>
                <y>30.0</y>
            </position>
        </doors>
        <name>RoomC1</name>
        <neighbours>CorridorF4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>5.0</x>
            <y>35.0</y>
        </boundingbox>
        <doors>
            <orientation>VERTICAL</orientation>
            <position>
                <x>10.0</x>
                <y>35.0</y>
            </position>
        </doors>
        <name>RoomA2</name>
        <neighbours>CorridorB4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>15.0</x>
            <y>35.0</y>
        </boundingbox>
        <name>CorridorB4</name>
        <neighbours>RoomA3</neighbours>
        <neighbours>RoomA2</neighbours>
        <neighbours>StartZoneC4</neighbours>
        <neighbours>RoomA1</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>25.0</x>
            <y>35.0</y>
        </boundingbox>
        <name>StartZoneC4</name>
        <neighbours>CorridorC3</neighbours>
        <neighbours>CorridorB4</neighbours>
        <neighbours>CorridorC5</neighbours>
        <neighbours>StartZoneD4</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>35.0</x>
            <y>35.0</y>
        </boundingbox>
        <name>StartZoneD4</name>
        <neighbours>StartZoneD3</neighbours>
        <neighbours>StartZoneC4</neighbours>
        <neighbours>FrontDropZone</neighbours>
        <neighbours>StartZoneE4</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>45.0</x>
            <y>35.0</y>
        </boundingbox>
        <name>StartZoneE4</name>
        <neighbours>CorridorE3</neighbours>
        <neighbours>StartZoneD4</neighbours>
        <neighbours>CorridorE5</neighbours>
        <neighbours>CorridorF4</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>55.0</x>
            <y>35.0</y>
        </boundingbox>
        <name>CorridorF4</name>
        <neighbours>RoomC1</neighbours>
        <neighbours>StartZoneE4</neighbours>
        <neighbours>RoomC2</neighbours>
        <neighbours>RoomC3</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>65.0</x>
            <y>35.0</y>
        </boundingbox>
        <doors>
            <orientation>VERTICAL</orientation>
            <position>
                <x>60.0</x>
                <y>35.0</y>
            </position>
        </doors>
        <name>RoomC2</name>
        <neighbours>CorridorF4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>15.0</x>
            <y>45.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>15.0</x>
                <y>40.0</y>
            </position>
        </doors>
        <name>RoomA1</name>
        <neighbours>CorridorB4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>25.0</x>
            <y>45.0</y>
        </boundingbox>
        <name>CorridorC5</name>
        <neighbours>StartZoneC4</neighbours>
        <neighbours>FrontDropZone</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>35.0</x>
            <y>45.0</y>
        </boundingbox>
        <name>FrontDropZone</name>
        <neighbours>StartZoneD4</neighbours>
        <neighbours>CorridorC5</neighbours>
        <neighbours>CorridorE5</neighbours>
        <neighbours>DropZone</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>45.0</x>
            <y>45.0</y>
        </boundingbox>
        <name>CorridorE5</name>
        <neighbours>StartZoneE4</neighbours>
        <neighbours>FrontDropZone</neighbours>
        <type>CORRIDOR</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>10.0</width>
            <x>55.0</x>
            <y>45.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>55.0</x>
                <y>40.0</y>
            </position>
        </doors>
        <name>RoomC3</name>
        <neighbours>CorridorF4</neighbours>
        <type>ROOM</type>
    </zones>
    <zones>
        <boundingbox>
            <height>10.0</height>
            <width>30.0</width>
            <x>35.0</x>
            <y>55.0</y>
        </boundingbox>
        <doors>
            <orientation>HORIZONTAL</orientation>
            <position>
                <x>35.0</x>
                <y>50.0</y>
            </position>
        </doors>
        <name>DropZone</name>
        <neighbours>FrontDropZone</neighbours>
        <type>ROOM</type>
    </zones>
</newMap>

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

@koenhindriks ok. I think we can drop the minimum distance requirement now that we changed the specification (pickUp and atBlock are now multiple).

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

Zone only contains the list of BlockColor so no actual blocks there.

The actual blocks are just created at 0,0 and then moved to their new position (MapLoader.findFreePlace). It seems we don't maintain a list of these.

actions like getting visible blcoks just iterates over all entities in the environment using repast context.getObjects(type)

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

There currently is a junit test that checks that exception is thrown if we place too many blocks (MapLoaderTest#createBlocksForRoomNoRoomTest()

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

All junit tests are fine except those 3 that explicitly check distance between blocks.

But while testing the Human GUI I ran into the issue that I may be unable to see some blocks.

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

Discussed that with Koen. i suggest the solution that we can try say 10 times to place a block without overlap, and if that fails we put it anywhere in the room with some overlap with other blocks.

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

@koenhindriks there appear more issues with the human GUI when blocks are overlapping

The main thing is that the GUI is designed assuming you can stand on at most one block.
So every menu item that reacts based on what block you are on now works only for the FIRST BLOCK of the pile you're standing on.

So suppose you stand on a pile with white, green and red block.

you get only "get white block" , "I am at white block", "room C2 contains a white block" etc.

You would have to pick up the block and put it down somewhere else before you can get the other options.

For now I assume that's the workaround we will have to recommend in the manual for such cases.

Please advise if this is OK

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

I also found 2 other issues

  1. When blocks overlap, the humanGUI and the server view show different top blocks. This is strange as both should use the same render code?

  2. When you pick up and put down a block in the same room, the block disappears

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

Putting down a blcok you get this WARNING

WARNING: request to perform 'putDown' was denied by the environment. because: performAction failed: ActException performAction failed:: RemoteException occurred in server thread; nested exception is: 
	java.rmi.RemoteException: action failed; nested exception is: 
	ActException type="failure" message="Action putDown with parameters [] failed to execute" cause="java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved": action failed; nested exception is: 
	ActException type="failure" message="Action putDown with parameters [] failed to execute" cause="java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved": Action putDown with parameters [] failed to execute: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved

stack dump:
nl.tudelft.bw4t.client.environment.ActionHandler.getActionPercept(ActionHandler.java:163)
nl.tudelft.bw4t.client.environment.ActionHandler.performActionDelegated(ActionHandler.java:48)
nl.tudelft.bw4t.client.environment.RemoteEnvironment.performAction(RemoteEnvironment.java:878)
goal.core.runtime.service.environmentport.EnvironmentPort.performAction(EnvironmentPort.java:220)
goal.core.agent.DefaultEnvironmentCapabilities.performAction(DefaultEnvironmentCapabilities.java:91)
goal.core.runtime.service.agent.RunState.doPerformAction(RunState.java:848)
goal.core.executors.actions.UserSpecActionExecutor.execute(UserSpecActionExecutor.java:132)
goal.core.executors.actions.ActionExecutor.perform(ActionExecutor.java:176)
goal.core.executors.stack.ActionStackExecutor.popped(ActionStackExecutor.java:175)
goal.core.executors.stack.CallStack.pop(CallStack.java:81)
goal.core.agent.GOALInterpreter.executeCycle(GOALInterpreter.java:353)
goal.core.agent.GOALInterpreter.access$3(GOALInterpreter.java:342)
goal.core.agent.GOALInterpreter$3.call(GOALInterpreter.java:365)
goal.core.agent.GOALInterpreter$3.call(GOALInterpreter.java:1)
goal.core.agent.GOALInterpreter$2.run(GOALInterpreter.java:298)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
-----which was caused by a deeper exception: java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: 
	java.rmi.RemoteException: action failed; nested exception is: 
	ActException type="failure" message="Action putDown with parameters [] failed to execute" cause="java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved"
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:355)
sun.rmi.transport.Transport$1.run(Transport.java:200)
sun.rmi.transport.Transport$1.run(Transport.java:197)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.Transport.serviceCall(Transport.java:196)
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:276)
sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:253)
sun.rmi.server.UnicastRef.invoke(UnicastRef.java:162)
java.rmi.server.RemoteObjectInvocationHandler.invokeRemoteMethod(RemoteObjectInvocationHandler.java:227)
java.rmi.server.RemoteObjectInvocationHandler.invoke(RemoteObjectInvocationHandler.java:179)
com.sun.proxy.$Proxy2.performEntityAction(Unknown Source)
nl.tudelft.bw4t.client.BW4TClient.performEntityAction(BW4TClient.java:234)
nl.tudelft.bw4t.client.environment.RemoteEnvironment.performEntityAction(RemoteEnvironment.java:500)
nl.tudelft.bw4t.client.environment.ActionHandler.getActionPercept(ActionHandler.java:158)
nl.tudelft.bw4t.client.environment.ActionHandler.performActionDelegated(ActionHandler.java:48)
nl.tudelft.bw4t.client.environment.RemoteEnvironment.performAction(RemoteEnvironment.java:878)
goal.core.runtime.service.environmentport.EnvironmentPort.performAction(EnvironmentPort.java:220)
goal.core.agent.DefaultEnvironmentCapabilities.performAction(DefaultEnvironmentCapabilities.java:91)
goal.core.runtime.service.agent.RunState.doPerformAction(RunState.java:848)
goal.core.executors.actions.UserSpecActionExecutor.execute(UserSpecActionExecutor.java:132)
goal.core.executors.actions.ActionExecutor.perform(ActionExecutor.java:176)
goal.core.executors.stack.ActionStackExecutor.popped(ActionStackExecutor.java:175)
goal.core.executors.stack.CallStack.pop(CallStack.java:81)
goal.core.agent.GOALInterpreter.executeCycle(GOALInterpreter.java:353)
goal.core.agent.GOALInterpreter.access$3(GOALInterpreter.java:342)
goal.core.agent.GOALInterpreter$3.call(GOALInterpreter.java:365)
goal.core.agent.GOALInterpreter$3.call(GOALInterpreter.java:1)
goal.core.agent.GOALInterpreter$2.run(GOALInterpreter.java:298)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
-----which was caused by a deeper exception: java.rmi.RemoteException: action failed; nested exception is: 
	ActException type="failure" message="Action putDown with parameters [] failed to execute" cause="java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved"
nl.tudelft.bw4t.server.BW4TServer.performEntityAction(BW4TServer.java:230)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:498)
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:324)
sun.rmi.transport.Transport$1.run(Transport.java:200)
sun.rmi.transport.Transport$1.run(Transport.java:197)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.Transport.serviceCall(Transport.java:196)
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
-----which was caused by a deeper exception: ActException type="failure" message="Action putDown with parameters [] failed to execute" cause="java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved"
eis.eis2java.handlers.DefaultActionHandler.performAction(DefaultActionHandler.java:126)
eis.eis2java.handlers.DefaultActionHandler.performAction(DefaultActionHandler.java:67)
eis.eis2java.environment.AbstractEnvironment.performEntityAction(AbstractEnvironment.java:191)
nl.tudelft.bw4t.server.environment.BW4TEnvironment.performClientAction(BW4TEnvironment.java:468)
nl.tudelft.bw4t.server.BW4TServer.performEntityAction(BW4TServer.java:228)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:498)
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:324)
sun.rmi.transport.Transport$1.run(Transport.java:200)
sun.rmi.transport.Transport$1.run(Transport.java:197)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.Transport.serviceCall(Transport.java:196)
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
-----which was caused by a deeper exception: java.lang.IllegalArgumentException: Object 'nl.tudelft.bw4t.server.model.blocks.Block@1' must be added to the space's context before it can be moved
repast.simphony.space.continuous.AbstractContinuousSpace.doMove(AbstractContinuousSpace.java:129)
repast.simphony.space.continuous.AbstractContinuousSpace.moveTo(AbstractContinuousSpace.java:121)
nl.tudelft.bw4t.server.model.BoundedMoveableObject.moveTo(BoundedMoveableObject.java:164)
nl.tudelft.bw4t.server.model.robots.AbstractRobot.drop(AbstractRobot.java:286)
nl.tudelft.bw4t.server.model.robots.handicap.AbstractRobotDecorator.drop(AbstractRobotDecorator.java:91)
nl.tudelft.bw4t.server.eis.RobotEntity.putDown(RobotEntity.java:695)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:498)
eis.eis2java.handlers.DefaultActionHandler.performAction(DefaultActionHandler.java:116)
eis.eis2java.handlers.DefaultActionHandler.performAction(DefaultActionHandler.java:67)
eis.eis2java.environment.AbstractEnvironment.performEntityAction(AbstractEnvironment.java:191)
nl.tudelft.bw4t.server.environment.BW4TEnvironment.performClientAction(BW4TEnvironment.java:468)
nl.tudelft.bw4t.server.BW4TServer.performEntityAction(BW4TServer.java:228)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:498)
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:324)
sun.rmi.transport.Transport$1.run(Transport.java:200)
sun.rmi.transport.Transport$1.run(Transport.java:197)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.Transport.serviceCall(Transport.java:196)
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683)
java.security.AccessController.doPrivileged(Native Method)
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)




from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

This is strange, 392 is the official release and this should just be working?

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

It DOES work correctly with the official 392 release.

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

Checked with Vincent. develop works fine there. Reset and cleaned my workspace. Now it works fine here too ...

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

We call Block.addToContext but "Block@1" is not re-added because Repast thinks it's already in the context

If you check the contents, (DefaultContext.addInternal) all Blocks are showing as "Block@1".

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

Wow, in Repast 2 blocks are equal if they have the same bbox and same servermap .....

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

It gives no problems if I put the blocks even .001 apart but when we have exactly the same doubles the problem occurs. This problem can occur both when adding and moving blocks. Maybe we can override BoundedMoveableObject.

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

raising to https://goalapl.atlassian.net/browse/ENV-1341

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

more on https://goalapl.atlassian.net/browse/ENV-1342

from bw4t.

Wouter1 avatar Wouter1 commented on August 11, 2024

@koenhindriks @Venorcis this has been fixed (on develop branch, not yet released)

from bw4t.

Related Issues (20)

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.