简体   繁体   English

自定义游戏地图的工作方式类似于Google Maps

[英]Custom game map working like Google Maps

I'm looking for a way to create a zoomable, draggable and customisable (add pins, draw trails, etc...) map using my own pictures (taken from various game maps). 我正在寻找一种使用自己的图片(从各种游戏地图中获取)来创建可缩放,可拖动和可自定义(添加图钉,绘制轨迹等)地图的方法。

I've found out about OpenLayers but I'm completely lost on how to use my custom files. 我已经找到有关OpenLayers的信息,但是我对如何使用自定义文件一无所知。 I've also heard about tiles naming convention but I'm a bit lost too 我也听说过瓷砖命名约定,但我也有点迷失

Could someone provide some input on what external script I could use (does OpenLayers fit my needs?) and how should I get started? 有人可以提供一些有关我可以使用的外部脚本的信息(OpenLayers符合我的需求吗?),我应该如何开始?

Thanks in advance 提前致谢

Google has a pretty cool exemple of their Google Maps API on the moon. Google在月球上有一个非常酷的Google Maps API示例。 You can find it here and it should be enough to get you started. 您可以在这里找到它,它应该足以让您入门。 It's using custom images and the code is documented, have fun :) 它正在使用自定义图像,并且记录了代码,玩得开心:)

I never used OpenLayers so I can't really help on that part, but you should try Google Maps first and see if It fits your needs. 我从没使用过OpenLayers,所以在这方面我真的没有帮助,但是您应该首先尝试Google Maps,看看它是否符合您的需求。 If not, you'll probably have more specific questions which OpenLayers might answer. 如果没有,您可能会有OpenLayers可能回答的更具体的问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM