diff --git a/.github/workflows/nexjast-ci.yml b/.github/workflows/nexjast-ci.yml
index 1fe85fd1..2841b208 100644
--- a/.github/workflows/nexjast-ci.yml
+++ b/.github/workflows/nexjast-ci.yml
@@ -1235,7 +1235,7 @@ jobs:
services:
mariadb:
- image: public.ecr.aws/docker/library/mariadb:11.4
+ image: mariadb:11.4
env:
MARIADB_ROOT_PASSWORD: ledgerroot
MARIADB_DATABASE: ogl_ledger_ci
@@ -1250,7 +1250,7 @@ jobs:
--health-retries=24
postgres:
- image: public.ecr.aws/docker/library/postgres:16
+ image: postgres:16
env:
POSTGRES_DB: ogl_ledger_ci
POSTGRES_USER: ledger
diff --git a/NexVerse/Server/Api/NexApiDocsPage.cs b/NexVerse/Server/Api/NexApiDocsPage.cs
index 02ca0301..565da090 100644
--- a/NexVerse/Server/Api/NexApiDocsPage.cs
+++ b/NexVerse/Server/Api/NexApiDocsPage.cs
@@ -353,6 +353,12 @@ main:before {content:"";position:fixed;inset:0;pointer-events:none;opacity:.17;z
Reserviert
Konflikt
+
Kartenkacheln werden bei Bedarf aus der öffentlichen Deutschland-API nachgeladen.
@@ -1219,6 +1225,24 @@ function gridViewport(){
return {minX,minY,maxX:minX+width-1,maxY:minY+height-1,width,height};
}
function gridCellKey(x,y){return x+':'+y}
+// Tile images are decorative; the authoritative occupancy/placement data
+// remains the authenticated Grid Control API. Cap requests for large viewports.
+function applyGridImagery(){
+ const enabled=$('gridShowWarp3d').checked;
+ let loaded=0, skipped=0;
+ document.querySelectorAll('#gridBoard .gridcell').forEach(cell=>{
+ if(enabled&&cell.classList.contains('occupied')){
+ if(loaded<200){
+ const x=Number(cell.dataset.x),y=Number(cell.dataset.y);
+ cell.style.backgroundImage='linear-gradient(rgba(6,18,32,.22),rgba(6,18,32,.22)),url("/api/v1/deutschland/tiles/1/'+x+'/'+y+'.jpg")';
+ cell.style.backgroundSize='cover';
+ loaded++;
+ }else{cell.style.backgroundImage='';skipped++;}
+ }else cell.style.backgroundImage='';
+ });
+ $('gridMapTileStatus').textContent=!enabled?'Kartenbilder ausgeblendet.'
+ :loaded+' Warp3D-Kacheln eingeblendet.'+(skipped?' Für große Ausschnitte sind maximal 200 Bilder gleichzeitig aktiv.':'');
+}
function applyGridFilter(){
const filter=$('gridFilter').value;
document.querySelectorAll('#gridBoard .gridcell').forEach(cell=>{
@@ -1312,6 +1336,7 @@ function renderGridLayout(data){
}
}
applyGridFilter();
+ applyGridImagery();
const counts=data.counts||{};
setGridStatus('Live · '+(counts.regions||0)+' Regionen · '+(counts.free||0)+' frei · '+(counts.occupied||0)+' belegt','good');
}
@@ -1956,7 +1981,7 @@ $('revokeFeatureLicense').addEventListener('click',()=>saveFeatureLicense(true))
$('loadNodes').addEventListener('click',loadNodes);$('clearNodesCredentials').addEventListener('click',()=>{$('nodesBearer').value='';$('nodesApiKey').value=''});
$('gridWest').addEventListener('click',()=>panGrid(-1,0));$('gridEast').addEventListener('click',()=>panGrid(1,0));$('gridSouth').addEventListener('click',()=>panGrid(0,-1));$('gridNorth').addEventListener('click',()=>panGrid(0,1));
$('validateGridPlacement').addEventListener('click',validateGridPlacement);$('gridRegionSizeX').addEventListener('change',()=>{if(gridSelected)validateGridPlacement()});$('gridRegionSizeY').addEventListener('change',()=>{if(gridSelected)validateGridPlacement()});
-$('gridCellPixels').addEventListener('input',()=>{$('gridBoard').style.setProperty('--cell',$('gridCellPixels').value+'px')});$('gridFilter').addEventListener('change',applyGridFilter);
+$('gridCellPixels').addEventListener('input',()=>{$('gridBoard').style.setProperty('--cell',$('gridCellPixels').value+'px')});$('gridFilter').addEventListener('change',applyGridFilter);$('gridShowWarp3d').addEventListener('change',applyGridImagery);
window.addEventListener('message',event=>{
if(event.origin!==window.parent.location.origin || event.source!==window.parent ||
diff --git a/NexVerse/Server/Api/NexCitizenWorldMapApi.cs b/NexVerse/Server/Api/NexCitizenWorldMapApi.cs
index e0d2fa44..9fdc9c9c 100644
--- a/NexVerse/Server/Api/NexCitizenWorldMapApi.cs
+++ b/NexVerse/Server/Api/NexCitizenWorldMapApi.cs
@@ -26,8 +26,10 @@ namespace NexVerse.Server.Api
private static readonly ILog m_Log = LogManager.GetLogger(typeof(NexCitizenWorldMapApi));
private const int CellMeters = 256;
private const int MaxWindowAxis = 16;
+ private const int MaxRegionAxisCells = 16; // up to 4096m VarRegions
private const int MaxCellCoordinate = (int.MaxValue - (CellMeters - 1)) / CellMeters;
private readonly IGridService m_Grid;
+ private IMapImageService m_MapImages;
private readonly string m_TeleportBaseUri;
public NexCitizenWorldMapApi(IGridService grid, string teleportBaseUri)
@@ -36,6 +38,10 @@ namespace NexVerse.Server.Api
m_TeleportBaseUri = (teleportBaseUri ?? string.Empty).TrimEnd('/');
}
+ // MapImageService publishes Warp3D imagery already uploaded by simulators.
+ // A missing optional map service must not break the existing World API.
+ internal void ConfigureTiles(IMapImageService mapImages) => m_MapImages = mapImages;
+
public void Handle(IOSHttpRequest request, IOSHttpResponse response)
{
if (!string.Equals(request?.HttpMethod, "GET", StringComparison.OrdinalIgnoreCase))
@@ -45,8 +51,17 @@ namespace NexVerse.Server.Api
return;
}
- if ((request.UriPath ?? string.Empty).TrimEnd('/').Equals(
- "/api/v1/world-map/view", StringComparison.OrdinalIgnoreCase))
+ string path = (request.UriPath ?? string.Empty).TrimEnd('/');
+ bool deutschland = path.StartsWith("/api/v1/deutschland", StringComparison.OrdinalIgnoreCase);
+ if (deutschland &&
+ path.StartsWith("/api/v1/deutschland/tiles/", StringComparison.OrdinalIgnoreCase))
+ {
+ HandleTile(path, response);
+ return;
+ }
+
+ if (path.Equals("/api/v1/world-map/view", StringComparison.OrdinalIgnoreCase) ||
+ path.Equals("/api/v1/deutschland/view", StringComparison.OrdinalIgnoreCase))
{
response.StatusCode = (int)HttpStatusCode.OK;
response.ContentType = "text/html; charset=utf-8";
@@ -56,12 +71,15 @@ namespace NexVerse.Server.Api
return;
}
- if (!(request.UriPath ?? string.Empty).TrimEnd('/').Equals(
- "/api/v1/world-map", StringComparison.OrdinalIgnoreCase))
+ if (!path.Equals("/api/v1/world-map", StringComparison.OrdinalIgnoreCase) &&
+ !path.Equals("/api/v1/deutschland", StringComparison.OrdinalIgnoreCase))
{
Json(response, HttpStatusCode.NotFound, new { error = "not_found" });
return;
}
+ string tileTemplate = deutschland
+ ? "/api/v1/deutschland/tiles/1/{x}/{y}.jpg"
+ : "/map/map-1-{x}-{y}-objects.jpg";
if (m_Grid == null)
{
@@ -93,6 +111,7 @@ namespace NexVerse.Server.Api
mode = "search",
query = search,
count = matches.Length,
+ tile_url_template = tileTemplate,
regions = matches.Select(PublicRegion).ToArray(),
correlation_id = NexApiRequestContext.Ensure(response)
});
@@ -128,7 +147,9 @@ namespace NexVerse.Server.Api
cell_size_meters = CellMeters,
mode = "viewport",
has_default_region = false,
- tile_url_template = "/map/map-1-{x}-{y}-objects.jpg",
+ tile_url_template = tileTemplate,
+ max_window_axis = MaxWindowAxis,
+ zoom_levels = 8,
regions = Array.Empty