Gwyneth Llewelyn
|
ee35407460
Deal with the issue of sending an invalid NPC key for an Agent that does not exist any more (because the database still does not reflect reality). Right now, I just skip dealing with that invalid Agent, but the whole engine infinite loop has to be rewritten to deal with Agents popping in and out.
|
7 years ago |
Gwyneth Llewelyn
|
48190dfc96
Minor changes in error messages when saving best path etc. to the database (they were copy & paste from elsewhere and not really obvious).
|
7 years ago |
Gwyneth Llewelyn
|
a621294ad2
Changed the movement of avatars so that they are made by a worker goroutine which will sleep for a second or so between movement calls. The main engine continues the calculation (in theory).
|
7 years ago |
Gwyneth Llewelyn
|
3e8b3e57b6
Added NullUUID for manually selecting avatar, too!
|
7 years ago |
Gwyneth Llewelyn
|
3bc986915f
Added option for NullUUID on the manual selection for a cube, because now we allow the user to override everything.
|
7 years ago |
Gwyneth Llewelyn
|
c60d8306bc
First round of debugging the engine. Added a bit more control over when to send messages (if the websocket is down) instead of timing out. JavaScript on the browser will now parse messages for engine ‘alerts’ to keep a similar UI than the PHP version (but HTML is on the template, not on the engine code side).
|
7 years ago |
Gwyneth Llewelyn
|
23677dbb0f
Full port of old PHP code finished. Now it’s debugging time, since there are clear differences in the results! Also, it seems that Go is four times slower; that has to be checked!
|
7 years ago |
Gwyneth Llewelyn
|
0e5c7864b0
Added the whole genetic algorithm to engine.go! There is just one last step before heavy debugging: actually giving the avatar the order to *move*, and save everything to the database. This was a massive porting from the old PHP code!
|
7 years ago |
Gwyneth Llewelyn
|
e03dbca4b0
Tried to sort things after generating population, but this doesn’t work yet.
|
7 years ago |
Gwyneth Llewelyn
|
c569b8dfd4
Adding initial population generation
|
7 years ago |
Gwyneth Llewelyn
|
22bb4d41c1
Adding some timing (just like the PHP version)
|
7 years ago |
Gwyneth Llewelyn
|
d89fd75d18
For the GA, changed Agents/Cubes to maps by UUID; added code to deal with user manually setting the cube (this still panics!)
|
7 years ago |
Gwyneth Llewelyn
|
893e9a904d
Simplifying calcDistance to make it FASTER!
|
7 years ago |
Gwyneth Llewelyn
|
a14f4e9fde
First checks to see what is the closest obstacle to each NPC.
|
7 years ago |
Gwyneth Llewelyn
|
56b677056d
Moving to MySQL. sqlite3 has problems with too much concurrency. Bug to be fixed: get unique indexes!
|
7 years ago |
Gwyneth Llewelyn
|
c0bb36d673
Trying to find a bug where the database gets locked and never unlocks again.
|
7 years ago |
Gwyneth Llewelyn
|
3682877317
First tweaks for the preparation of the engine
|
7 years ago |
Gwyneth Llewelyn
|
359e95615a
Fixed minor SQL syntax bug.
|
7 years ago |
Gwyneth Llewelyn
|
4c7b60b91f
Changes made to open the database and put it all in memory before the engine starts. With some debugging output.
|
7 years ago |
Gwyneth Llewelyn
|
49dd4b610c
Added some comments regarding the choice of sync/atomic
|
7 years ago |
Gwyneth Llewelyn
|
5796ff9592
Work done to control remotely the engine, with visual feedback
|
7 years ago |
Gwyneth Llewelyn
|
f81bb52567
First attempt to fix concurrent access at the engneRunning status variable using sync/atomic, but it seems not to be working, need to understand better how this package actually works
|
7 years ago |
Gwyneth Llewelyn
|
eff861e9ed
Engine running as a goroutine from the start, engine page is dealing with start/stop, messages are being sent and received, but still some tweaking with shared variables needed.
|
7 years ago |
Gwyneth Llewelyn
|
11f4786eab
Replaced fake paralelate() function with engine(), which does little more than running a for loop and waiting for messages to be received
|
7 years ago |
Gwyneth Llewelyn
|
b57d7c8cb7
Two-way communication using WebSockets and JSON for more structured message data. So far it seems to work… until Go crashes when receiving data for the formEngine submission
|
7 years ago |
Gwyneth Llewelyn
|
2fb050ceeb
Preparing the Engine to respond to the form selecting agents & cubes. The engine doesn’t do anything, but it’s all prepared for giving commands to agents to move to destinations!
|
7 years ago |
Gwyneth Llewelyn
|
3903fa183f
Preparing the Engine to respond to the form selecting agents & cubes. It’s non-functional right now and does not compile, caveat utility!
|
7 years ago |
Gwyneth Llewelyn
|
7958701360
Working with WebSockets to update the Engine page display, which is crucial as we enter the next stage, which is to get the engine actually doing something — and logging what it does on the respective page.
|
7 years ago |
Gwyneth Llewelyn
|
6215d28c62
- Made gobot respond to signals; send a SIGHUP to get it to reload the configuration!
|
7 years ago |
Gwyneth Llewelyn
|
88f91db4a3
Attempt to use Gravatars (works) with their Hovercards (doesn’t work yet)
|
7 years ago |