地图编辑器 / Map Editor#
“创造你自己的战场,设计你自己的挑战。” / “Create your own battlefield, design your own challenges.”
《要塞》内置了强大的地图编辑器,让你可以创建自定义地图和剧本。本章将详细介绍地图编辑器的使用方法、自定义地图制作和脚本编写。
“Stronghold” includes a powerful map editor, allowing you to create custom maps and scenarios. This chapter provides detailed information on using the map editor, custom map creation, and scripting.
地图编辑器概览 / Map Editor Overview#
编辑器功能 / Editor Features#
| 功能 / Feature |
说明 / Description |
难度 / Difficulty |
| 地形编辑 / Terrain editing |
修改地形高度和类型 / Modify terrain height and type |
简单 / Easy |
| 建筑放置 / Building placement |
放置预设建筑 / Place preset buildings |
简单 / Easy |
| 单位放置 / Unit placement |
放置初始单位 / Place initial units |
中等 / Medium |
| 资源设置 / Resource setting |
设置初始资源 / Set initial resources |
简单 / Easy |
| 脚本编写 / Scripting |
编写游戏脚本 / Write game scripts |
困难 / Hard |
| 触发器设置 / Trigger setup |
设置事件触发器 / Set event triggers |
中等 / Medium |
编辑器界面 / Editor Interface#
| 界面元素 / Interface Element |
功能 / Function |
| 工具栏 / Toolbar |
各种编辑工具 / Various editing tools |
| 地图视图 / Map view |
显示和编辑地图 / Display and edit map |
| 属性面板 / Properties panel |
修改对象属性 / Modify object properties |
| 图层管理 / Layer management |
管理地图图层 / Manage map layers |
| 脚本编辑器 / Script editor |
编写游戏脚本 / Write game scripts |
地形编辑 / Terrain Editing#
地形类型 / Terrain Types#
| 地形 / Terrain |
特点 / Characteristics |
建造限制 / Build Limits |
| 平地 / Flat land |
平坦地形 / Flat terrain |
可建造任何建筑 / Can build any building |
| 丘陵 / Hills |
起伏地形 / Undulating terrain |
部分建筑受限 / Some buildings limited |
| 山地 / Mountains |
高耸地形 / Tall terrain |
无法建造 / Cannot build |
| 水域 / Water |
河流湖泊 / Rivers and lakes |
无法建造,可捕鱼 / Cannot build, can fish |
| 森林 / Forest |
树木覆盖 / Tree coverage |
可伐木 / Can chop wood |
| 工具 / Tool |
功能 / Function |
使用方法 / Usage |
| 提升地形 / Raise terrain |
提高地形高度 / Raise terrain height |
点击并拖动 / Click and drag |
| 降低地形 / Lower terrain |
降低地形高度 / Lower terrain height |
点击并拖动 / Click and drag |
| 平整地形 / Flatten terrain |
平整地形 / Flatten terrain |
点击目标区域 / Click target area |
| 填充水域 / Fill water |
创建水域 / Create water |
点击并拖动 / Click and drag |
| 种植树木 / Plant trees |
种植树木 / Plant trees |
点击位置 / Click position |
地形编辑技巧 / Terrain Editing Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 利用高地 / Use high ground |
创建战略高地 / Create strategic high ground |
战术优势 / Tactical advantage |
| 创建河流 / Create rivers |
创建自然屏障 / Create natural barriers |
防御优势 / Defense advantage |
| 设计关隘 / Design passes |
创建狭窄通道 / Create narrow passages |
伏击机会 / Ambush opportunities |
| 平整基地 / Flatten base |
创建平坦建造区 / Create flat building area |
方便建造 / Easy construction |
建筑放置 / Building Placement#
预设建筑 / Preset Buildings#
| 建筑类型 / Building Type |
放置要求 / Placement Requirements |
数量限制 / Quantity Limits |
| 经济建筑 / Economy buildings |
平地 / Flat land |
无限制 / Unlimited |
| 军事建筑 / Military buildings |
平地 / Flat land |
无限制 / Unlimited |
| 防御建筑 / Defense buildings |
按类型 / Depends on type |
无限制 / Unlimited |
| 装饰建筑 / Decoration buildings |
平地 / Flat land |
无限制 / Unlimited |
建筑放置技巧 / Building Placement Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 预设基地 / Preset base |
预先建造基地 / Preset base buildings |
快速开局 / Quick start |
| 预设防御 / Preset defense |
预先建造防御 / Preset defense buildings |
固定防御 / Fixed defense |
| 预设资源 / Preset resources |
预设资源建筑 / Preset resource buildings |
固定经济 / Fixed economy |
| 美观布局 / Aesthetic layout |
注重美观 / Focus on beauty |
视觉享受 / Visual enjoyment |
单位放置 / Unit Placement#
初始单位设置 / Initial Unit Setting#
| 单位类型 / Unit Type |
放置要求 / Placement Requirements |
数量限制 / Quantity Limits |
| 步兵 / Infantry |
平地 / Flat land |
根据地图大小 / Based on map size |
| 远程单位 / Ranged units |
平地 / Flat land |
根据地图大小 / Based on map size |
| 骑兵 / Cavalry |
平地 / Flat land |
根据地图大小 / Based on map size |
| 攻城武器 / Siege weapons |
平地 / Flat land |
根据地图大小 / Based on map size |
单位放置技巧 / Unit Placement Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 平衡兵力 / Balance forces |
各方兵力均衡 / Balanced forces |
公平对战 / Fair battle |
| 制造不平衡 / Create imbalance |
刻意制造不平衡 / Deliberately imbalance |
挑战性对战 / Challenging battle |
| 设置伏兵 / Set ambush |
隐藏单位设置伏兵 / Hide units for ambush |
突袭效果 / Surprise effect |
| 预设援军 / Preset reinforcements |
预设援军位置 / Preset reinforcement positions |
增援效果 / Reinforcement effect |
资源设置 / Resource Setting#
初始资源设置 / Initial Resource Setting#
| 资源 / Resource |
设置方法 / Setting Method |
默认值 / Default |
| 木材 / Wood |
滑块调整 / Slider adjustment |
100 / 100 |
| 石头 / Stone |
滑块调整 / Slider adjustment |
50 / 50 |
| 铁 / Iron |
滑块调整 / Slider adjustment |
20 / 20 |
| 金 / Gold |
滑块调整 / Slider adjustment |
500 / 500 |
| 食物 / Food |
滑块调整 / Slider adjustment |
100 / 100 |
资源设置技巧 / Resource Setting Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 平衡资源 / Balance resources |
各方资源均衡 / Balanced resources |
公平对战 / Fair battle |
| 丰富资源 / Abundant resources |
设置大量资源 / Set abundant resources |
快速发展 / Rapid development |
| 匮乏资源 / Scarce resources |
设置少量资源 / Set scarce resources |
资源争夺 / Resource competition |
| 特殊资源 / Special resources |
设置特殊资源分布 / Set special resource distribution |
战略要点 / Strategic points |
脚本编写 / Scripting#
脚本基础 / Script Basics#
| 概念 / Concept |
说明 / Description |
示例 / Example |
| 触发器 / Trigger |
事件触发条件 / Event trigger condition |
时间到达、单位死亡等 / Time reached, unit dies, etc. |
| 动作 / Action |
触发后执行的动作 / Action executed after trigger |
显示消息、生成单位等 / Show message, spawn units, etc. |
| 条件 / Condition |
动作执行条件 / Action execution condition |
资源足够、单位存在等 / Resources enough, units exist, etc. |
| 变量 / Variable |
存储数据的容器 / Data storage container |
计数器、标志位等 / Counters, flags, etc. |
常用脚本示例 / Common Script Examples#
时间触发 / Time Trigger:
当时间到达10分钟时,显示消息
When time reaches 10 minutes, show message
触发器:时间 == 10分钟
Trigger: Time == 10 minutes
动作:显示消息 "敌人援军即将到来!"
Action: Show message "Enemy reinforcements approaching!"
单位死亡触发 / Unit Death Trigger:
当所有敌方单位死亡时,胜利
When all enemy units die, victory
触发器:敌方单位数量 == 0
Trigger: Enemy unit count == 0
动作:显示胜利消息
Action: Show victory message
资源触发 / Resource Trigger:
当资源达到1000时,解锁新建筑
When resources reach 1000, unlock new building
触发器:资源 >= 1000
Trigger: Resources >= 1000
动作:解锁新建筑
Action: Unlock new building
脚本编写技巧 / Scripting Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 从小脚本开始 / Start small |
从简单脚本开始 / Start with simple scripts |
逐步学习 / Gradual learning |
| 测试脚本 / Test scripts |
每次修改后测试 / Test after each modification |
确保正常工作 / Ensure works correctly |
| 使用注释 / Use comments |
添加注释说明 / Add comments for explanation |
方便理解 / Easy to understand |
| 备份脚本 / Backup scripts |
定期备份脚本 / Regularly backup scripts |
防止丢失 / Prevent loss |
触发器系统 / Trigger System#
触发器类型 / Trigger Types#
| 触发器类型 / Trigger Type |
说明 / Description |
示例 / Example |
| 时间触发器 / Time trigger |
基于时间 / Based on time |
5分钟后 / After 5 minutes |
| 单位触发器 / Unit trigger |
基于单位事件 / Based on unit events |
单位死亡、建造完成等 / Unit dies, building complete, etc. |
| 资源触发器 / Resource trigger |
基于资源数量 / Based on resource amount |
资源达到1000 / Resources reach 1000 |
| 位置触发器 / Location trigger |
基于单位位置 / Based on unit position |
单位进入区域 / Unit enters area |
| 事件触发器 / Event trigger |
基于游戏事件 / Based on game events |
战斗开始、建筑摧毁等 / Battle starts, building destroyed, etc. |
触发器设置技巧 / Trigger Setup Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 多重条件 / Multiple conditions |
设置多个条件 / Set multiple conditions |
精确控制 / Precise control |
| 延迟触发 / Delayed trigger |
设置延迟时间 / Set delay time |
控制节奏 / Control rhythm |
| 循环触发 / Loop trigger |
设置循环执行 / Set loop execution |
持续效果 / Continuous effect |
| 条件嵌套 / Nested conditions |
条件中包含条件 / Conditions within conditions |
复杂逻辑 / Complex logic |
自定义地图制作 / Custom Map Creation#
制作流程 / Creation Process#
| 步骤 / Step |
操作 / Action |
时间 / Time |
| 1. 规划设计 / Plan design |
规划地图布局和目标 / Plan map layout and objectives |
1-2小时 / 1-2 hours |
| 2. 地形编辑 / Terrain editing |
编辑地形和水域 / Edit terrain and water |
2-4小时 / 2-4 hours |
| 3. 建筑放置 / Building placement |
放置预设建筑 / Place preset buildings |
1-2小时 / 1-2 hours |
| 4. 单位放置 / Unit placement |
放置初始单位 / Place initial units |
0.5-1小时 / 0.5-1 hour |
| 5. 脚本编写 / Scripting |
编写游戏脚本 / Write game scripts |
2-4小时 / 2-4 hours |
| 6. 测试调整 / Test and adjust |
测试并调整 / Test and adjust |
1-2小时 / 1-2 hours |
地图类型设计 / Map Type Design#
| 地图类型 / Map Type |
设计要点 / Design Points |
难度 / Difficulty |
| 死亡竞赛地图 / Deathmatch map |
平衡资源、开阔地形 / Balanced resources, open terrain |
中等 / Medium |
| 夺旗地图 / CTF map |
对称设计、明确旗帜位置 / Symmetric design, clear flag positions |
中等 / Medium |
| 征服地图 / Conquest map |
多个据点、战略要点 / Multiple points, strategic points |
困难 / Hard |
| 剧情地图 / Story map |
完整剧情、任务目标 / Complete story, mission objectives |
困难 / Hard |
地图设计技巧 / Map Design Tips#
| 技巧 / Tip |
说明 / Description |
效果 / Effect |
| 对称设计 / Symmetric design |
地图对称 / Symmetric map |
公平对战 / Fair battle |
| 战略要点 / Strategic points |
设置关键位置 / Set key positions |
战术深度 / Tactical depth |
| 多样地形 / Diverse terrain |
使用多种地形 / Use multiple terrains |
视觉丰富 / Visual richness |
| 测试平衡 / Test balance |
反复测试平衡 / Repeatedly test balance |
确保公平 / Ensure fairness |
地图分享 / Map Sharing#
分享方法 / Sharing Methods#
| 方法 / Method |
说明 / Description |
推荐 / Recommendation |
| 游戏内分享 / In-game sharing |
通过游戏内功能分享 / Share via in-game feature |
推荐 / Recommended |
| 文件分享 / File sharing |
分享地图文件 / Share map files |
常用 / Common |
| 社区分享 / Community sharing |
在社区分享 / Share in community |
扩大影响 / Expand reach |
分享注意事项 / Sharing Notes#
| 注意事项 / Note |
说明 / Description |
| 文件大小 / File size |
注意地图文件大小 / Watch map file size |
| 版本兼容 / Version compatibility |
确保版本兼容 / Ensure version compatibility |
| 测试充分 / Test thoroughly |
分享前充分测试 / Test thoroughly before sharing |
| 版权说明 / Copyright |
注明原创作者 / Credit original author |
总结 / Summary#
《要塞》的地图编辑器功能强大,让你可以创造自己的游戏内容。从简单的地形编辑到复杂的脚本编写,都能在这里实现。发挥你的创造力,设计出独特的地图和剧本,与朋友分享你的创作。
The map editor of “Stronghold” is powerful, allowing you to create your own game content. From simple terrain editing to complex scripting, everything is possible here. Unleash your creativity, design unique maps and scenarios, and share your creations with friends.
“地图编辑器是创造力的舞台。在这里,你的想象力没有边界。” / “The map editor is a stage for creativity. Here, your imagination has no limits.”