跳到正文
原文
Reddit · ClaudeCode / Codex / VibeCoding· /u/Worldly_Chemistry_81·· 1天前AI 评分17

用 Claude Opus 5.5 在 BeamNG 里 1:1 重建瑞士提契诺 52 km² 拉力赛道路

原文标题:I couldn't afford a rally car (or the skills), so I rebuilt my home region's rally roads in BeamNG at 1:1: 52 km² of Ticino, Switzerland

AI 导读

一位瑞士开发者用 Claude Opus 5.5 打造工具,基于 swisstopo 的 0.5 m 分辨率 LiDAR 地形数据等开放数据,在 BeamNG.drive 中 1:1 重建了家乡 Malcantone 地区约 52 km² 地图(v2.7),含 228 km 道路、167 座桥、12,792 栋建筑和约 161,000 棵树。

正文

当前语言的正文正在等待翻译,暂时显示原文。

Every year there's a rally in my region, the Malcantone (the hilly corner of Ticino, Switzerland, west of Lugano, right on the Italian border). I've always wanted to take part, but I have neither a rally car nor the skills, hahaahahah. So I figured the next best thing was to drive those roads in BeamNG.

I first tried MapNG, but its elevation data is only about 30 m resolution, so the roads I know by heart just didn't feel right. Switzerland has something much better: swisstopo's swissALTI3D, a LiDAR terrain model at 0.5 m resolution. In the game the terrain is a 12.3 × 12.3 km grid at 1.5 m, with heights within about ±0.3 m of the survey inside the area.

So, together with Claude (Opus 5.5), I built a tool that generates the whole map from open data: swisstopo (terrain, roads, buildings, aerial photos), the official cadastral survey of Canton Ticino, the Federal Register of Buildings and OpenStreetMap. Nothing is modelled by hand.

What's in it right now (v2.7):

  • about 52 km² at 1:1 scale, from Ponte Tresa and Caslano to Agno, Bioggio, Gravesano and Arosio, with Lake Lugano
  • 228 km of roads and 337 km of trails, mule tracks and forest roads, all drivable, with 167 bridges
  • gravel, dirt, setts and cobblestones that change the grip
  • 12,792 buildings with façades, about 161,000 trees, rivers and vineyards
  • Swiss road signs and markings, AI traffic on the whole network, 30 spawn points (one per village)
  • some good drives: the Magliaso to Pura cantonal road, the Penudria hairpins from Gravesano up to Arosio, the lakeside road through Caslano

It's not perfect, but it's realistic enough that I, as someone who lives there, recognise every road and every village without any trouble.

It scales, too. The map is generated from an area outline you draw, and the swisstopo data it uses covers the whole of Switzerland. So in theory you could fork the repo, draw a different outline and build your own piece of the country, the Swiss Alps included. In practice each map has to stay a region rather than the whole country (52 km² already needs about 12 GB of RAM in game), and outside Ticino you'd point the cadastral and building downloads at your own canton.

The project is absolutely not finished and keeps evolving. I'm very open to feedback, bug reports and screenshots (a GitHub issue with the village and road helps a lot), and I'd be really happy if people from all over the world got to drive my favourite roads.

Repo: https://github.com/wintrymichi/magliasinaNG
Download (v2.7): https://github.com/wintrymichi/magliasinaNG/releases/tag/v2.7

Needs BeamNG.drive 0.39 and 16 GB of RAM; drop the zip in your mods folder without unpacking it.

来源:Reddit · ClaudeCode / Codex / VibeCoding · reddit.com