• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Tibia 7.7 Map Editor for Original CipSoft .sec Files (PyQt5) - Pre-Alpha

rajmek126p

Active Member
Joined
Nov 13, 2020
Messages
13
Reaction score
30
Hello OTLand community!

I'd like to share a project I've been working on recently. Inspired by the amazing work of fusion32 on his tibia-game project (which reverse-engineers the original Tibia 7.7 client), I decided to tackle something that I believe has been missing in the OT community for a long time: a proper map editor that works directly with the original CipSoft .sec sector files.

Unlike most OT map editors that work with OTBM format, this editor reads and writes the original binary .sec files used by the real Tibia 7.7 server. If you've ever worked with the original CipSoft server files (dat/, mon/, npc/, origmap/), you know that editing those maps has always been a pain. This project aims to change that.

How It Was Built

The editor is written entirely in Python 3 using PyQt5 (Qt5 framework) for the GUI. The rendering engine is based on QGraphicsView / QGraphicsScene, which provides hardware-accelerated 2D rendering with built-in zoom, pan, and viewport culling.

Technology Stack:
  • Python 3 - Core language
  • PyQt5 - GUI framework (QMainWindow, QGraphicsView, QGraphicsScene, QToolBar, QMenu, etc.)
  • struct module - Binary parsing of .sec, .spr, .dat files
  • Custom binary parsers - Hand-written parsers for every CipSoft file format (sec_parser.py, creature_sprites.py, sprite_manager.py)
  • Dark theme - Full dark mode UI via Qt stylesheets

The project is fully modular - each component (map canvas, tile editor, item palette, server data loader, creature sprite extractor, undo/redo system) is its own Python module.

Complete Feature List

Core Map Editing
  • Native .sec format support - Reads and writes original CipSoft sector files (XXXX-YYYY-ZZ.sec). Full binary parsing including tile flags, item stacking, teleport destination encoding/decoding (AbsTeleportDestination format).
  • Real Tibia 7.7 sprites - Renders actual item sprites extracted from the game files. Multi-tile items (2x2, 2x3, etc.) are correctly positioned with the anchor tile at bottom-right.
  • Z-ordered rendering - Items are rendered in correct priority layers: Bank (ground) → Clip → Bottom → Top → Normal, with proper overlap calculation based on world position.
  • 5 drawing tools - Select, Draw, Erase, Area Select, and Flood Fill (bucket tool). Each tool supports brush sizes from 1x1 up to 7x7.
  • Full Undo/Redo system - Command-pattern based with up to 100 operations. Supports undo for: draw item, erase item, paste tiles, flood fill, move/remove items, change flags, change attributes.
  • Copy/Cut/Paste - Select rectangular areas, copy/cut tiles to clipboard, paste with live preview following the cursor. Escape to cancel. Supports full tile stacks with all items and attributes.
  • Flood Fill - BFS-based flood fill that replaces connected ground tiles of the same type. Safety limit of 5000 tiles per fill operation.
  • 16 floor levels - Full support for Z levels 0-15. Quick floor switching with PageUp/PageDown or arrow buttons. Floor change reloads all sectors for the new Z.

Full Map Loading with Viewport Culling
  • Load All Sectors - Can load the entire map for a given floor (thousands of .sec files) with a progress dialog.
  • Viewport culling - When the full map is loaded, only sectors visible in the viewport (+1 buffer) are rendered. Sectors outside the view are dynamically unloaded and reloaded as you scroll/zoom. This keeps the editor responsive even with 9000+ sectors loaded.
  • Autoloader - On startup, automatically detects and loads map data from the local origmap/ folder and server data from dat/, mon/, npc/ folders.
  • Load Everything - One-click button to load all map sectors + all server data with a two-phase progress dialog (0-80% map, 80-100% server data).

Server Data Integration
  • monster.db - Loads all monster spawn definitions (race, position, radius, amount, regen time). Displays spawn points on the map with actual creature sprites.
  • *.mon files - Parses monster race definitions (name, outfit/looktype, HP, experience).
  • *.npc files - Loads NPC definitions (name, home position, radius, sex, outfit).
  • houses.dat + houseareas.dat - Loads house definitions with field positions, exit points, rent info, and area/town associations.
  • map.dat - Loads map marks (named locations like cities, dungeons), depots, and player start positions (newbie/veteran).
  • moveuse.dat - Parses teleport rules (both absolute and relative MoveTop/MoveRel) with section tracking.
  • *.evt files - Loads raid/event definitions with spawn intervals and positions.
  • objects.srv - Parses all 66 item flags and attributes for proper item classification and rendering.

Creature Sprite Extraction (Tibia.spr + Tibia.dat)
  • Binary .spr parser - Reads the original Tibia.spr file, parses the sprite offset table, and extracts individual 32x32 sprites using RLE decompression (transparency runs + RGB colored pixel runs).
  • Binary .dat parser - Parses the Tibia.dat file header (items/outfits/effects/distances counts), skips all item entries, and extracts outfit entries with full sprite layout information (width, height, layers, pattern X/Y/Z, animation phases).
  • LookType mapping - Maps server LookType IDs to .dat outfit entries. Supports all 254 outfits from Tibia 7.7.
  • Direction & animation support - Each outfit has 4 directions (N/E/S/W) and multiple animation frames. Monsters are rendered facing south by default.
  • Multi-tile creature compositing - Large creatures (2x2 tile outfits like Cyclops, Demon, Hydra) are composited from 4 individual sprites into a single pixmap.
  • Sprite caching - Rendered outfit pixmaps are cached by (looktype, direction) for fast repeated access.

Visual Overlays (10 types)
  • Grid (G) - Shows tile grid with highlighted sector boundaries (32x32).
  • Lower Floor Preview (L) - Semi-transparent rendering of the floor below for reference.
  • Protection Zones (Z) - Green tint on PZ tiles, purple on NoLogout zones.
  • Teleport Markers (T) - Orange highlight with "T" label on tiles containing teleport items.
  • Ingame Viewport Box (I) - Shows the actual Tibia 7.7 client viewport (15x11 tiles) as a green rectangle.
  • Blocking/Unpassable (B) - Red overlay on tiles with blocking items (excludes ground).
  • Light Sources (J) - Visualizes light source items with colored glow circles.
  • Navigation Spots (R) - Green highlight on rope spots and climb areas.
  • Monster Spawns (M) - Renders actual creature sprites at spawn positions with name labels, amount, and spawn radius circle.
  • NPC Positions (N) - Renders NPC outfit sprites at their home positions with name labels.
  • House Areas (H) - Semi-transparent overlay on house tiles with exit markers and house name labels.
  • Server Teleports (P) - Purple markers from moveuse.dat with destination coordinates.
  • Map Marks (K) - Yellow labels for named locations (cities, dungeons, POIs).
  • Toggle All (Ctrl+Shift+O) - Enable/disable all server overlays at once.

Right-Click Context Menu (Full Editing)
  • Tile actions - Select tile, copy position, copy item ID
  • Teleport navigation - Jump to teleport destination
  • Server data info - Shows all monsters, NPCs, houses, teleports at the clicked position
  • Map mark management - Add, edit, delete named locations
  • Monster spawn management - Add new spawn (with race dropdown of all loaded monsters), edit spawn (position, amount, radius, regen time), move spawn, delete spawn
  • NPC management - Add new NPC (name, radius, outfit), edit NPC (all properties), delete NPC
  • Teleport management - Add new teleport (item type + destination), edit destination, navigate to destination, delete teleport

Find & Replace
  • Find Items (Ctrl+F) - Search by Item ID, Item Name, Action ID, or Unique ID. Found tiles are highlighted on the map and the view centers on the first match.
  • Replace Items (Ctrl+H) - Replace one item ID with another across the entire loaded map or within a selected area. Shows replacement count.

Tile Editor Panel
  • Tile position display - Shows X, Y, Z coordinates
  • Flag editing - Toggle ProtectionZone, NoLogoutZone, Refresh flags with checkboxes
  • Item stack view - Lists all items on the tile with sprites, IDs, names
  • Attribute display - Shows ActionId, UniqueId, Text, Teleport destination for each item
  • Flag badges - Color-coded badges for item properties (Unpass, Unmove, Unthrow, Light, Container, Take, Top, Bottom, etc.)
  • Item reordering - Move items up/down in the stack
  • Item removal - Remove specific items from tiles

Item Palette
  • Search - Search by ID number or item name (case-insensitive, debounced)
  • 19 categories - All Items, Ground Tiles, Objects, Containers, Doors, Keys, Food, Runes, Weapons, Shields, Armor, Lights, Teleports, Readable, Writable, Hangable, Rotatable, Blocking, Cumulative
  • Grid display - 8-column grid of clickable item buttons with sprite previews
  • Item preview - Large preview with ID and name for selected item

Other Features
  • Minimap widget - Small overview showing all loaded sectors. Green = has tiles, gray = empty. Clickable to navigate.
  • Screenshot export (Ctrl+Shift+S) - Export visible map area as PNG/JPEG image.
  • Map Statistics - Detailed breakdown: sector count, tile count, PZ/NoLogout tiles, item stats, server data summary.
  • Recent Maps - Remembers up to 5 recently opened map folders.
  • Save All (Ctrl+Alt+S) - Saves both modified map sectors and server data (monster.db) in one operation.
  • Full keyboard shortcuts - Tools (S/D/E/A/F), overlays (G/L/Z/T/I/B/J/R/M/N/H/P/K), brush sizes (1/2/3/4), floor navigation (PageUp/PageDown).
  • Zoom - Mouse wheel zoom (12.5% to 400%) anchored at cursor position.
  • Pan - Middle mouse button drag to pan the map.

Pre-Alpha Status & Known Issues

I want to be transparent - this is a pre-alpha project. It works and is usable, but it has some rough edges:

  • Some visual bugs with multi-tile sprite positioning in certain edge cases
  • The creature sprite rendering doesn't apply outfit colors (head/body/legs/feet color tinting) yet - creatures are shown with their base template colors
  • Performance can drop when displaying thousands of monster overlays simultaneously on the full map
  • The NPC save function preserves only position data (full .npc file regeneration is not implemented yet)
  • Some item flag combinations from objects.srv may not be parsed 100% correctly
  • The UI could use more polish - some dialogs are basic
  • No rotation/mirror support for items yet
  • Moveuse.dat save only preserves the original file (new teleport rules added via editor are stored in memory but not appended to the file yet)

Looking for Testers & Feedback

I have a few questions for the community:

  1. Does a project like this make sense? Is there actual demand for a .sec format map editor, or is everyone happy with OTBM-based workflows? I know there are still people running CipSoft-based servers who might benefit from this.
  2. Would anyone be willing to test it? I'm looking for people who have access to original Tibia 7.7 server files (or similar 7.x versions) to test the editor with their maps. Feedback on bugs, missing features, or usability issues would be incredibly valuable.
  3. What features would you prioritize? I have a long list of planned improvements but I'd love to hear what the community considers most important.

If you're interested in testing or contributing, let me know! I can share the source code and setup instructions.

Thanks for reading, and a huge thanks to fusion32 for the tibia-game project that made this possible by documenting the original file formats!

Note: This project is not affiliated with CipSoft in any way. It is a fan-made tool for educational and hobbyist purposes.
 

Attachments

  • Screenshot_1886.webp
    Screenshot_1886.webp
    661.6 KB · Views: 307 · VirusTotal
  • Screenshot_1887.webp
    Screenshot_1887.webp
    727 KB · Views: 347 · VirusTotal
  • Screenshot_1888.webp
    Screenshot_1888.webp
    580.1 KB · Views: 338 · VirusTotal
  • Screenshot_1889.webp
    Screenshot_1889.webp
    441.5 KB · Views: 360 · VirusTotal
@rajmek126p Judging by the third screenshot (that candelabrum under the table), you load objects in the wrong order. On each tile, Cip first saves objects with ground/order-related flags from bottom to top, and then other objects from top to bottom. So, first go: "ground", "clip", "bottom", "top" flag objects (if present), in this order, and then the rest goes in reversed order. You probably read everything from bottom to top, which is why that candelabrum ends up under the table rather than on top of it. I reported the same issue to @kor regarding his mapper.
 
Looking good 😮, maybe:

Blue? tint on refreshable tiles

Ability to add fluid type (water, blood, beer etc) on fluid container (like vial).

Copy tiles from another map

Import another map (maybe including coordinates)
 
Last edited:
This is a cool project. I went all the way converting the recently released 7.5 map from .sec to OTBM just so I could avoid using a prehistoric 2008 version of RME to explore the converted .sec files.
 
Update -- What's changed since the initial post

Hey everyone, thanks for the feedback! Here's a summary of improvements made since the pre-alpha announcement.



@kay -- You were absolutely right about the rendering order. I've fixed it -- items now render in correct priority: Ground -> Clip -> Bottom -> Top, and then Normal items in reverse order (as CipSoft .sec files store the topmost item first). The candelabrum-on-table issue and similar Z-ordering problems should be resolved. Thanks for pointing this out, it was a critical fix.

@rudger -- Great suggestions, I'll keep those in mind for future updates. Fluid types on containers and cross-map copy/import are solid ideas.

@Way20 -- Thanks! That's exactly the pain point this editor aims to solve -- no more converting .sec to OTBM just to edit a 7.7 map.



Changes & new features since the original post:

Rendering Engine (major overhaul):
  • Fixed item rendering order: Bank(0) -> Clip(1) -> Bottom(2) -> Top(3) -> Normal(reversed) -- proper painter's algorithm with correct Z-layering
  • Fixed multi-tile sprite positioning -- sprites now anchor correctly at bottom-right with proper top-left offset
  • Implemented elevation system -- items with the Height flag now create visual platforms, shifting items above them up and to the left (matching original Tibia 7.7 behavior)
  • Creature outfit colorization now works -- full Tibia color palette (133 colors) with template layer tinting (head/body/legs/feet)
  • Most visual bugs from the pre-alpha are now fixed

Sprite Manager improvements:
  • LRU cache with 4000-sprite limit and automatic batch eviction -- prevents memory leaks on large maps
  • Disguise system for items that should render as another item's sprite
  • Pattern variant selection based on world coordinates (proper ground tiling)

New editing tools & features:
  • Brush sizes: 1x1, 3x3, 5x5, 7x7
  • Eyedropper tool -- sample items directly from the map
  • Find & Replace with 8 search modes: Item ID, Item Name, Action ID, Unique ID, Key Number, Keyhole Number, Chest Quest Number, Text Content -- with live map highlighting
  • Flood Fill for ground replacement across connected areas

Server data editors:
  • Spawn Editor -- add/edit creature spawns with race search, amount, radius, regen time
  • NPC Editor -- name, sex, race, outfit string with live preview, walk radius
  • House Editor -- full house management with auto-ID, rent, guild flags, exit/center positions; includes a House Manager dialog with searchable table and go-to navigation
  • Teleport Editor -- manage moveuse.dat rules with source/destination positions

Undo/Redo system:
  • Command pattern with up to 100 history steps
  • Supports: DrawItem, EraseItem, MoveItem, RemoveItem, ChangeFlag, ChangeAttr, PasteTiles, FloodFill
  • Visual undo history panel with descriptions

Tile Editor improvements:
  • Edit all 18 CipSoft instance attributes (text, teleport destinations, quest numbers, door properties, key/keyhole, charges, liquid types, etc.)
  • Move items up/down in the tile stack
  • Tile flag management (Refresh, ProtectionZone, NoLogoutZone)

Performance:
  • Viewport culling with smart sector loading/unloading and 1-sector buffer
  • Debounced layout updates (50ms) for smooth scrolling on large maps
  • Full map mode now handles all 9800+ sectors without choking

Distribution:
  • PyInstaller build ready -- standalone .exe, no Python installation needed
  • Dark-themed UI throughout
 

Attachments

  • Screenshot_1940.webp
    Screenshot_1940.webp
    691.4 KB · Views: 117 · VirusTotal
  • Screenshot_1941.webp
    Screenshot_1941.webp
    862.6 KB · Views: 115 · VirusTotal
  • Screenshot_1942.webp
    Screenshot_1942.webp
    508.7 KB · Views: 118 · VirusTotal
It looks very nice! Especially that it's built in Python!
Was it vibecoded?
 
AI helps me a lot with the map editor, but I treat it as an assistant, not an autopilot. I design the architecture, make the key decisions, and do the review/refactor work so I keep full control over the code.
 
@rajmek126p maybe if you are able to remove all moveable items from the 7.5 converted map with this editor (those items that dont have unmoveable flag i guess?) And load all moveable items from the 7.72 origmap into this map, with some manually work we might be able to have something close to the 7.5 origmap? Im not sure if its feasible, but if we are able to compare 7.72 sec file against 7.5 sec file and add the moveable items in the correct order maybe it is possible. @kay what is your opinion on this? Im not sure if that is the only flag we would need to check tho, but maybe its feasible.
 
@rajmek126p maybe if you are able to remove all moveable items from the 7.5 converted map with this editor (those items that dont have unmoveable flag i guess?) And load all moveable items from the 7.72 origmap into this map, with some manually work we might be able to have something close to the 7.5 origmap? Im not sure if its feasible, but if we are able to compare 7.72 sec file against 7.5 sec file and add the moveable items in the correct order maybe it is possible. @kay what is your opinion on this? Im not sure if that is the only flag we would need to check tho, but maybe its feasible.
I'm already working on that on my free time, I will release it as soon as I finish (I want to release it in both formats .sec and OTBM). Other specific checks would also be necessary for any items on the environment that players can affect like doors, ovens, lamps etc.
 
Update 2 — Tibia 7.5 Map Support & Full Map Merge System

@Terotrificy — You were spot on. That's exactly what im built. Your idea of comparing .sec files between versions and transferring moveable items was the foundation of this entire update. It works, and it works well.

@Way20 — You mentioned working on a similar approach — I'd love to compare notes. The key discovery we made is that TypeIDs are identical between 7.5 and 7.72, which simplified things enormously. More on that below.



What this update adds:

The editor can now open, render, and merge original CipSoft Tibia 7.5 binary .sec map files — producing a hybrid map that combines the 7.5 world structure (terrain, buildings, walls, stairs, decorations) with 7.72 dynamic content (quest items, NPC furniture, moveable objects, container contents). The result is the closest possible reconstruction of the original 7.5 map with correct gameplay content.



Phase 1: Tibia 7.5 Binary .sec Format Support

The 7.5 map format is completely different from 7.7:

  • Filenames: 7.5 uses 7-character hexadecimal names (e.g. 0FF8FC6.sec) encoding sector X/Y/Z in a packed format. 7.7 uses decimal with dashes (e.g. 1020-1002-08.sec).
  • Content: 7.5 is pure binary (header + tiles + item stacks with binary instance attributes). 7.7 is human-readable text.
  • Item references: 7.5 stores items as (Group, Number) pairs from conversion.lst, not direct TypeIDs. Each pair maps to a TypeID via the conversion table.
  • Instance attributes: 7.5 encodes all 18 CipSoft instance attributes (ChestQuestNumber, KeyNumber, teleport destinations, text strings, container content, etc.) as binary quads. The attribute layout per item depends on which flags that item type has in objects.srv — so the parser must know every item's flags to correctly decode the binary stream.

We built a complete binary parser (sec_parser_75.py) that handles all of this, including nested container content (recursive binary parsing), and a converter that translates 7.5 sectors into the 7.7 text format used by the editor internally.

Auto-detection: The editor automatically detects whether origmap/ contains 7.5 hex files or 7.7 decimal files and loads the correct parser. No manual configuration needed.

Sprite rendering: For 7.5 maps, we use 7.55 client sprites (Tibia.dat + Tibia.spr from a 7.55 client). This works because the TypeIDs from conversion.lst are the same as the Client IDs in the 7.55 .dat file — the server and client share the same ID space starting from version 7.55.



Phase 2: Item Classification Engine

This is the brain of the merge system. Every single item type (5,003 items from objects.srv) is automatically classified into one of three categories:

STATIC (3,759 items) — structural world elements kept from the 7.5 map:
  • Ground tiles (Bank flag)
  • Walls, borders, cliff edges (Unmove flag)
  • Stairs, ladders, holes, level changes
  • Fixed containers like quest chests (Container + Unmove) — the chest shell stays from 7.5
  • Doors (all 4 door types: KeyDoor, NameDoor, LevelDoor, QuestDoor)
  • Decorations, structural elements, terrain features

DYNAMIC (1,236 items) — moveable/gameplay content taken from 7.72:
  • Anything with Take flag (pickupable items)
  • Weapons, armor, shields, food, runes
  • Cumulative/stackable items
  • Moveable containers (bags, backpacks, baskets)
  • Writable items (letters, scrolls)
  • Hangable items (if also Take)

AMBIGUOUS (8 items) — couldn't be auto-classified, kept from 7.5 as the safer default.

The classifier works by analyzing the flag combinations from objects.srv. No hardcoded item ID lists — it's purely flag-driven, so it adapts to any objects.srv file.



Phase 3: Map Merge Engine — The Core

This is where @Terotrificy's idea becomes reality. The merge processes all 16 Z-levels (0-15) across both maps:

Key discovery — TypeIDs are identical:
We validated that conversion.lst TypeIDs (used in 7.5 binary .sec) are exactly the same as the TypeIDs in objects.srv (used in 7.7 text .sec). 4,294 out of 4,294 entries have a 1:1 match. No ID translation is needed between versions. This was the single biggest simplification — it means items from both maps can be directly mixed without any mapping table.

The merge algorithm (per tile):
  1. Start with the 7.5 tile — iterate through all items
  2. Keep every STATIC item (terrain, walls, structure) from 7.5
  3. Strip every DYNAMIC item from 7.5 (we don't want 7.5's moveable placements)
  4. Keep AMBIGUOUS items from 7.5 (safer to preserve structure)
  5. From the matching 7.7 tile — collect all DYNAMIC items
  6. Append the 7.7 dynamic items on top of the 7.5 static structure
  7. Use tile flags from 7.7 (more up-to-date: Refresh, ProtectionZone, NoLogoutZone)

Special case — Fixed containers (quest chests):
Chests like reward chests (Container + Unmove) need special handling. The chest itself is structural (stays from 7.5), but its contents are dynamic gameplay items that should come from 7.7. So we do a "container content merge": shell from 7.5, nested Content from 7.7. This preserves the chest's position in the tile stack while giving it the correct quest rewards, ChestQuestNumber values, and nested item chains.

Edge cases handled:
  • Sectors only in 7.5 (6 sectors): Kept with dynamic items stripped — pure structural data.
  • Sectors only in 7.7 (401 sectors): Skipped by default for a pure 7.5 footprint. Use --include-77-only to include them (new areas added between versions — underground expansions, new caves, etc.)
  • Tile exists only in one version: Used as-is from whichever version has it.

Merge statistics (full run):
Code:
Sectors merged (both versions):   9,472
Sectors only in 7.5:                  6
Sectors only in 7.7:                401 (skipped by default)
Total output sectors:             9,478 (or 9,879 with --include-77-only)

Tiles merged:                 7,521,338
Static items kept (from 7.5): 7,968,174
Dynamic items added (from 7.7):  18,591
Dynamic items stripped (from 7.5):99,677
Container content merged:            370
Ambiguous items (kept from 7.5):     359

Errors: 0
Duration: ~211 seconds

Zero errors across almost 10,000 sectors and 7.5 million tiles.



Phase 4: Visual Merge Tools

  • Merge Report: Full JSON report (merge_report.json) with per-Z-level statistics, ambiguous item log with positions, and error tracking.
  • Item Category Overlay (F4): Toggle an overlay in the editor that color-codes tiles: green = tiles containing dynamic items, yellow = tiles with ambiguous items. Pure static tiles have no overlay. Useful for visually verifying the merge result.
  • Map Diff Dialog: Side-by-side comparison between map versions (was already in the editor from a previous update).



Phase 5: Server Data

Since TypeIDs are identical, server data files are used as-is from 7.7:

  • moveuse.dat — 828 collision events (teleporters, level doors, quest triggers), 414 use events, 312 separation events — all copied directly. Teleporters work because they reference TypeIDs and world positions, both of which are the same.
  • monster.db — all monster definitions
  • mon/ directory — 195 spawn files
  • npc/ directory — 376 NPC definition files
  • houses.dat, houseareas.dat, owners.dat — full house system
  • Total: 581 server data files copied



Technical Architecture (for the curious)

The merge system is split into cleanly separated modules:

  • sec_parser_75.py — Full binary .sec parser with IA (Instance Attribute) decoding. Knows how to read the binary quad stream by consulting each item's flags to determine which attributes are present.
  • dat_parser_75.py — Tibia 7.5 .dat parser (different flag byte structure than 7.7).
  • objects_srv.py — Shared singleton parser for objects.srv + conversion.lst. Used by all modules (no more duplicate parsing).
  • item_classifier.py — Flag-driven classification engine (STATIC/DYNAMIC/AMBIGUOUS).
  • map_merger.py — Merge engine with CLI interface. Can be run standalone: python map_merger.py --map75 origmap --map77 origmap.bak --output merged_map



The Result

The editor now loads the merged map (9,478 sectors — pure 7.5 footprint) as origmap/ and everything works — rendering, editing, tile inspection, quest data (ChestQuestNumber, DoorQuest, KeyNumber, etc.), teleporters, spawn overlays, NPC positions, house boundaries. The map has 7.5 terrain structure with 7.7 gameplay content, exactly as intended.

If anyone wants to try this with their own 7.5 binary map files — the editor auto-detects the format. Just drop hex-named .sec files into origmap/ and the 7.7 map into origmap.bak/, run the merger, and you get a hybrid map.



Known Limitations & Caveats — Read Before You Get Too Excited

Let's be honest about what this approach cannot solve automatically. The merge gives you a 7.5 terrain structure, but the dynamic content layer is fundamentally from 7.70/7.72. That comes with real consequences:

1. Quests are from 7.70, not 7.5
  • All ChestQuestNumbers, DoorQuestNumbers, DoorQuestValues, and quest-related scripting (moveuse.dat) come from the 7.72 server data. If a quest was added between 7.5 and 7.72, it will be present on the merged map even though it didn't exist in the original 7.5.
  • Conversely, if CipSoft changed a quest's reward chest location or quest number between versions, the merged map has the 7.72 version of that quest, not the 7.5 one.
  • Quest triggers that depend on specific terrain layouts may not work correctly if the 7.5 terrain around them differs from 7.72.

2. NPCs sell items that don't exist in 7.5
  • NPC trade lists, dialogues, and scripts come from 7.72. NPCs may reference, sell, or buy items that were added after 7.5. A shopkeeper might offer an item that has a valid TypeID in 7.72 objects.srv but the client 7.5 has no sprite for it. This requires manual NPC script editing to match the 7.5 item pool.
  • NPC positions are from 7.72 — if a shop was relocated or a new NPC was added between versions, they'll be at 7.72 positions which may not match the 7.5 building layout.

3. Moveuse.dat is from 7.72
  • All teleporter destinations, level door requirements, quest door checks, and special use actions are from 7.72. Teleporters added after 7.5 will reference positions that may look different on the 7.5 terrain. Since the 401 post-7.5 sectors are excluded by default, some teleporters may point to areas that don't exist on the merged map — those will need to be removed or redirected manually.
  • Some existing teleporters may have had their destinations adjusted between versions.

4. Monster/creature spawns are from 7.72
  • Spawn files (mon/ directory) are from 7.72. If CipSoft added new spawn areas, moved spawns, changed creature types, or adjusted spawn rates between 7.5 and 7.72, the merged map reflects the 7.72 state. Since the 401 post-7.5 sectors are excluded by default, some spawn files may reference positions in areas that no longer exist on the map — those spawns will simply not work and should be cleaned up.
  • There's no way to recover the original 7.5 spawn data from the binary .sec files alone — spawn data was always in separate server-side files.

5. New map areas (401 sectors) — excluded by default, optionally includable
  • 401 sectors exist only in 7.72 (underground expansions, new islands, caves added between versions). By default, the merger skips these — the output contains only sectors that existed in the original 7.5 map, giving you a pure 7.5 world footprint (9,478 sectors).
  • If you want a fuller map that includes post-7.5 areas, run the merger with --include-77-only and those 401 extra sectors will be copied as-is (with 7.72 terrain + items). This gives you 9,879 sectors — useful if you want the complete world but don't mind having some non-7.5 areas mixed in.

6. House system is from 7.72
  • House definitions, boundaries, rent values, and ownership data are from 7.72. If houses were added, resized, or repriced between versions, the merged map has the 7.72 house layout.

7. Items placed between versions
  • We strip ~99,700 dynamic items from the 7.5 map and add ~18,600 from 7.72. The 7.72 dynamic items include everything CipSoft placed between 7.5 and 7.72 — furniture in new houses, decorations in new areas, quest items for new quests. These are mixed in with the "original" items that existed in both versions.
  • There's no way to distinguish "this barrel was placed in 7.5" from "this barrel was added in 7.6" — both just appear as item 1234 on a tile in the 7.72 map.

Bottom line: The merge produces 7.5 terrain + 7.72 gameplay. It's the best automated approximation of a 7.5 origmap, but it's not a time machine. To get a truly authentic 7.5 experience, you'd need the original 7.5 server data files (moveuse.dat, monster.db, NPC scripts, house data) — which, as far as I know, nobody has. The binary .sec map files only contain the structural/item layer, not the server logic layer.

For a playable 7.5-like server, manual cleanup is expected: reviewing NPC trade lists against the 7.5 item pool, checking quest chains, removing teleporters that point to non-existent post-7.5 areas, cleaning up spawns in missing sectors, and possibly removing post-7.5 quest data. The editor's search tools (Find by ChestQuestNumber, Item ID, etc.) and the category overlay (F4) are designed to help with exactly this kind of manual review.



Still pre-alpha, more updates coming. Feedback and ideas welcome as always — especially if anyone has 7.5 server data to compare against.
 

Attachments

  • Screenshot_1962.webp
    Screenshot_1962.webp
    706.4 KB · Views: 101 · VirusTotal
  • Screenshot_1964.webp
    Screenshot_1964.webp
    741.3 KB · Views: 91 · VirusTotal
  • Screenshot_1965.webp
    Screenshot_1965.webp
    732.4 KB · Views: 93 · VirusTotal
  • Screenshot_1966.webp
    Screenshot_1966.webp
    833.3 KB · Views: 81 · VirusTotal
  • Screenshot_1970.webp
    Screenshot_1970.webp
    486.2 KB · Views: 100 · VirusTotal
Last edited:
Update 2 — Tibia 7.5 Map Support & Full Map Merge System

@Terotrificy — You were spot on. That's exactly what im built. Your idea of comparing .sec files between versions and transferring moveable items was the foundation of this entire update. It works, and it works well.

@Way20 — You mentioned working on a similar approach — I'd love to compare notes. The key discovery we made is that TypeIDs are identical between 7.5 and 7.72, which simplified things enormously. More on that below.



What this update adds:

The editor can now open, render, and merge original CipSoft Tibia 7.5 binary .sec map files — producing a hybrid map that combines the 7.5 world structure (terrain, buildings, walls, stairs, decorations) with 7.72 dynamic content (quest items, NPC furniture, moveable objects, container contents). The result is the closest possible reconstruction of the original 7.5 map with correct gameplay content.



Phase 1: Tibia 7.5 Binary .sec Format Support

The 7.5 map format is completely different from 7.7:

  • Filenames: 7.5 uses 7-character hexadecimal names (e.g. 0FF8FC6.sec) encoding sector X/Y/Z in a packed format. 7.7 uses decimal with dashes (e.g. 1020-1002-08.sec).
  • Content: 7.5 is pure binary (header + tiles + item stacks with binary instance attributes). 7.7 is human-readable text.
  • Item references: 7.5 stores items as (Group, Number) pairs from conversion.lst, not direct TypeIDs. Each pair maps to a TypeID via the conversion table.
  • Instance attributes: 7.5 encodes all 18 CipSoft instance attributes (ChestQuestNumber, KeyNumber, teleport destinations, text strings, container content, etc.) as binary quads. The attribute layout per item depends on which flags that item type has in objects.srv — so the parser must know every item's flags to correctly decode the binary stream.

We built a complete binary parser (sec_parser_75.py) that handles all of this, including nested container content (recursive binary parsing), and a converter that translates 7.5 sectors into the 7.7 text format used by the editor internally.

Auto-detection: The editor automatically detects whether origmap/ contains 7.5 hex files or 7.7 decimal files and loads the correct parser. No manual configuration needed.

Sprite rendering: For 7.5 maps, we use 7.55 client sprites (Tibia.dat + Tibia.spr from a 7.55 client). This works because the TypeIDs from conversion.lst are the same as the Client IDs in the 7.55 .dat file — the server and client share the same ID space starting from version 7.55.



Phase 2: Item Classification Engine

This is the brain of the merge system. Every single item type (5,003 items from objects.srv) is automatically classified into one of three categories:

STATIC (3,759 items) — structural world elements kept from the 7.5 map:
  • Ground tiles (Bank flag)
  • Walls, borders, cliff edges (Unmove flag)
  • Stairs, ladders, holes, level changes
  • Fixed containers like quest chests (Container + Unmove) — the chest shell stays from 7.5
  • Doors (all 4 door types: KeyDoor, NameDoor, LevelDoor, QuestDoor)
  • Decorations, structural elements, terrain features

DYNAMIC (1,236 items) — moveable/gameplay content taken from 7.72:
  • Anything with Take flag (pickupable items)
  • Weapons, armor, shields, food, runes
  • Cumulative/stackable items
  • Moveable containers (bags, backpacks, baskets)
  • Writable items (letters, scrolls)
  • Hangable items (if also Take)

AMBIGUOUS (8 items) — couldn't be auto-classified, kept from 7.5 as the safer default.

The classifier works by analyzing the flag combinations from objects.srv. No hardcoded item ID lists — it's purely flag-driven, so it adapts to any objects.srv file.



Phase 3: Map Merge Engine — The Core

This is where @Terotrificy's idea becomes reality. The merge processes all 16 Z-levels (0-15) across both maps:

Key discovery — TypeIDs are identical:
We validated that conversion.lst TypeIDs (used in 7.5 binary .sec) are exactly the same as the TypeIDs in objects.srv (used in 7.7 text .sec). 4,294 out of 4,294 entries have a 1:1 match. No ID translation is needed between versions. This was the single biggest simplification — it means items from both maps can be directly mixed without any mapping table.

The merge algorithm (per tile):
  1. Start with the 7.5 tile — iterate through all items
  2. Keep every STATIC item (terrain, walls, structure) from 7.5
  3. Strip every DYNAMIC item from 7.5 (we don't want 7.5's moveable placements)
  4. Keep AMBIGUOUS items from 7.5 (safer to preserve structure)
  5. From the matching 7.7 tile — collect all DYNAMIC items
  6. Append the 7.7 dynamic items on top of the 7.5 static structure
  7. Use tile flags from 7.7 (more up-to-date: Refresh, ProtectionZone, NoLogoutZone)

Special case — Fixed containers (quest chests):
Chests like reward chests (Container + Unmove) need special handling. The chest itself is structural (stays from 7.5), but its contents are dynamic gameplay items that should come from 7.7. So we do a "container content merge": shell from 7.5, nested Content from 7.7. This preserves the chest's position in the tile stack while giving it the correct quest rewards, ChestQuestNumber values, and nested item chains.

Edge cases handled:
  • Sectors only in 7.5 (6 sectors): Kept with dynamic items stripped — pure structural data.
  • Sectors only in 7.7 (401 sectors): Skipped by default for a pure 7.5 footprint. Use --include-77-only to include them (new areas added between versions — underground expansions, new caves, etc.)
  • Tile exists only in one version: Used as-is from whichever version has it.

Merge statistics (full run):
Code:
Sectors merged (both versions):   9,472
Sectors only in 7.5:                  6
Sectors only in 7.7:                401 (skipped by default)
Total output sectors:             9,478 (or 9,879 with --include-77-only)

Tiles merged:                 7,521,338
Static items kept (from 7.5): 7,968,174
Dynamic items added (from 7.7):  18,591
Dynamic items stripped (from 7.5):99,677
Container content merged:            370
Ambiguous items (kept from 7.5):     359

Errors: 0
Duration: ~211 seconds

Zero errors across almost 10,000 sectors and 7.5 million tiles.



Phase 4: Visual Merge Tools

  • Merge Report: Full JSON report (merge_report.json) with per-Z-level statistics, ambiguous item log with positions, and error tracking.
  • Item Category Overlay (F4): Toggle an overlay in the editor that color-codes tiles: green = tiles containing dynamic items, yellow = tiles with ambiguous items. Pure static tiles have no overlay. Useful for visually verifying the merge result.
  • Map Diff Dialog: Side-by-side comparison between map versions (was already in the editor from a previous update).



Phase 5: Server Data

Since TypeIDs are identical, server data files are used as-is from 7.7:

  • moveuse.dat — 828 collision events (teleporters, level doors, quest triggers), 414 use events, 312 separation events — all copied directly. Teleporters work because they reference TypeIDs and world positions, both of which are the same.
  • monster.db — all monster definitions
  • mon/ directory — 195 spawn files
  • npc/ directory — 376 NPC definition files
  • houses.dat, houseareas.dat, owners.dat — full house system
  • Total: 581 server data files copied



Technical Architecture (for the curious)

The merge system is split into cleanly separated modules:

  • sec_parser_75.py — Full binary .sec parser with IA (Instance Attribute) decoding. Knows how to read the binary quad stream by consulting each item's flags to determine which attributes are present.
  • dat_parser_75.py — Tibia 7.5 .dat parser (different flag byte structure than 7.7).
  • objects_srv.py — Shared singleton parser for objects.srv + conversion.lst. Used by all modules (no more duplicate parsing).
  • item_classifier.py — Flag-driven classification engine (STATIC/DYNAMIC/AMBIGUOUS).
  • map_merger.py — Merge engine with CLI interface. Can be run standalone: python map_merger.py --map75 origmap --map77 origmap.bak --output merged_map



The Result

The editor now loads the merged map (9,478 sectors — pure 7.5 footprint) as origmap/ and everything works — rendering, editing, tile inspection, quest data (ChestQuestNumber, DoorQuest, KeyNumber, etc.), teleporters, spawn overlays, NPC positions, house boundaries. The map has 7.5 terrain structure with 7.7 gameplay content, exactly as intended.

If anyone wants to try this with their own 7.5 binary map files — the editor auto-detects the format. Just drop hex-named .sec files into origmap/ and the 7.7 map into origmap.bak/, run the merger, and you get a hybrid map.



Known Limitations & Caveats — Read Before You Get Too Excited

Let's be honest about what this approach cannot solve automatically. The merge gives you a 7.5 terrain structure, but the dynamic content layer is fundamentally from 7.70/7.72. That comes with real consequences:

1. Quests are from 7.70, not 7.5
  • All ChestQuestNumbers, DoorQuestNumbers, DoorQuestValues, and quest-related scripting (moveuse.dat) come from the 7.72 server data. If a quest was added between 7.5 and 7.72, it will be present on the merged map even though it didn't exist in the original 7.5.
  • Conversely, if CipSoft changed a quest's reward chest location or quest number between versions, the merged map has the 7.72 version of that quest, not the 7.5 one.
  • Quest triggers that depend on specific terrain layouts may not work correctly if the 7.5 terrain around them differs from 7.72.

2. NPCs sell items that don't exist in 7.5
  • NPC trade lists, dialogues, and scripts come from 7.72. NPCs may reference, sell, or buy items that were added after 7.5. A shopkeeper might offer an item that has a valid TypeID in 7.72 objects.srv but the client 7.5 has no sprite for it. This requires manual NPC script editing to match the 7.5 item pool.
  • NPC positions are from 7.72 — if a shop was relocated or a new NPC was added between versions, they'll be at 7.72 positions which may not match the 7.5 building layout.

3. Moveuse.dat is from 7.72
  • All teleporter destinations, level door requirements, quest door checks, and special use actions are from 7.72. Teleporters added after 7.5 will reference positions that may look different on the 7.5 terrain. Since the 401 post-7.5 sectors are excluded by default, some teleporters may point to areas that don't exist on the merged map — those will need to be removed or redirected manually.
  • Some existing teleporters may have had their destinations adjusted between versions.

4. Monster/creature spawns are from 7.72
  • Spawn files (mon/ directory) are from 7.72. If CipSoft added new spawn areas, moved spawns, changed creature types, or adjusted spawn rates between 7.5 and 7.72, the merged map reflects the 7.72 state. Since the 401 post-7.5 sectors are excluded by default, some spawn files may reference positions in areas that no longer exist on the map — those spawns will simply not work and should be cleaned up.
  • There's no way to recover the original 7.5 spawn data from the binary .sec files alone — spawn data was always in separate server-side files.

5. New map areas (401 sectors) — excluded by default, optionally includable
  • 401 sectors exist only in 7.72 (underground expansions, new islands, caves added between versions). By default, the merger skips these — the output contains only sectors that existed in the original 7.5 map, giving you a pure 7.5 world footprint (9,478 sectors).
  • If you want a fuller map that includes post-7.5 areas, run the merger with --include-77-only and those 401 extra sectors will be copied as-is (with 7.72 terrain + items). This gives you 9,879 sectors — useful if you want the complete world but don't mind having some non-7.5 areas mixed in.

6. House system is from 7.72
  • House definitions, boundaries, rent values, and ownership data are from 7.72. If houses were added, resized, or repriced between versions, the merged map has the 7.72 house layout.

7. Items placed between versions
  • We strip ~99,700 dynamic items from the 7.5 map and add ~18,600 from 7.72. The 7.72 dynamic items include everything CipSoft placed between 7.5 and 7.72 — furniture in new houses, decorations in new areas, quest items for new quests. These are mixed in with the "original" items that existed in both versions.
  • There's no way to distinguish "this barrel was placed in 7.5" from "this barrel was added in 7.6" — both just appear as item 1234 on a tile in the 7.72 map.

Bottom line: The merge produces 7.5 terrain + 7.72 gameplay. It's the best automated approximation of a 7.5 origmap, but it's not a time machine. To get a truly authentic 7.5 experience, you'd need the original 7.5 server data files (moveuse.dat, monster.db, NPC scripts, house data) — which, as far as I know, nobody has. The binary .sec map files only contain the structural/item layer, not the server logic layer.

For a playable 7.5-like server, manual cleanup is expected: reviewing NPC trade lists against the 7.5 item pool, checking quest chains, removing teleporters that point to non-existent post-7.5 areas, cleaning up spawns in missing sectors, and possibly removing post-7.5 quest data. The editor's search tools (Find by ChestQuestNumber, Item ID, etc.) and the category overlay (F4) are designed to help with exactly this kind of manual review.



Still pre-alpha, more updates coming. Feedback and ideas welcome as always — especially if anyone has 7.5 server data to compare against.
Jesus, I didn't expect that reply at all lol truly amazing!
 
Awesome job, a good .sec editor was indeed needed for the community!
I created a "origmap" of 7.5 in the other topic, but not 100%. This one looks amazing
I would like to help.
 
Update 3 — Full 7.55 Compatibility Cleanup: Removing Everything That Shouldn't Exist

Following up on the map merge system from Update 2. After merging the 7.5 terrain with 7.72 dynamic content, we ran a deep audit of the entire dataset — every .sec sector, every spawn, every teleporter, every NPC script, every monster loot table, and every quest attribute — to strip out anything that doesn't belong in 7.55. The merged map is now fully clean.



What was cleaned and why

The merge gave us 7.5 terrain + 7.72 gameplay content. But the 7.72 data contains things added between versions — items the 7.55 client can't render, spawn points in sectors that don't exist on the 7.5 map, teleporters leading to nowhere, NPCs selling phantom items, monster loot referencing non-existent drops, and quest attributes that were added post-7.5. All of that is now gone.

How we determined the correct item threshold:
The 7.55 Tibia.dat header declares last_item_id = 4402 — meaning the client has sprite data for TypeIDs 100-4402 only. conversion.lst (the 7.5 server's item mapping table) covers TypeIDs 100-4393 with zero gaps. Items 4394-4402 exist in the client but aren't referenced by the 7.5 server — they're harmless "rock soil" variants. Anything above 4402 has no client sprite and would render as invisible/broken. That's our hard cutoff.



1. Invalid Items Removed from Map (7,009 instances)

Scanned all 9,478 sectors (~8 million item instances). Found and removed 7,009 items with TypeIDs above 4402 — items that have no sprite data in the 7.55 Tibia.dat and would render as invisible/broken objects. Cross-verified against the original 7.5 binary map: zero of these items exist there — they all came from the 7.72 layer.

Breakdown by category:
  • Flat roof tiles (IDs 5048-5054): ~3,882 instances — 7.7+ roof tiles CipSoft added for building tops.
  • Ship/port decorations (IDs 4904-5007): ~1,580 instances — ship cabin walls, railings, masts, sails, steering wheels, rudder blades, hawsers, bollards, anchors, ventilation grilles.
  • Mountain/terrain variants (IDs 4403-4468): ~1,486 instances — new rock soil, rocks, and mountain tile variants added post-7.55. Found across 333 sectors.
  • Ground tile variants (IDs 4515-4553, 4749-4758): ~47 instances — new grass, gravel, and sand variants.
  • Miscellaneous: red carpets (4860-4862), skull variants (5015/5017), magic forcefield (5022), panda teddy (5080), new door types (5082/5084) — ~14 instances.

After cleanup: 0 items with ID > 4402 remain on the map. Every single item is now renderable by the 7.55 client.



2. Quest Attributes — Verified Against Original 7.5 Binary Map

This was the big question: are the quest numbers on the merged map actually authentic 7.5 data, or did 7.72 contamination sneak in?

We parsed both the original 7.5 binary map (origmap_75/) and the merged map, extracting every quest-related attribute from every item on every tile. Then compared them:

Code:
Attribute              Original 7.5    Merged map    New (post-7.5)    Action
──────────────────────────────────────────────────────────────────────────────
ChestQuestNumber            210            210              0           ✓ clean
DoorQuestNumber              22             23              1           removed
KeyNumber                     8              8              0           ✓ clean
KeyholeNumber                74             74              0           ✓ clean

All 210 ChestQuestNumbers are 100% authentic from the original 7.5 binary map. Zero added, zero lost. The chest quests survived the merge process perfectly — they come from the 7.5 structural layer (chests are STATIC items with Container+Unmove flags), so the merger preserved them from the 7.5 source as intended.

Same story for KeyNumbers (8/8) and KeyholeNumbers (74/74) — all identical to the 7.5 original.

The one exception: DoorQuestNumber 320 — a quest door at position (32500, 31622, 6) that was added after 7.5. The quest attributes (DQ=320, DQV=5) were zeroed out, turning it back into a normal door. All 22 original 7.5 DoorQuestNumbers remain intact.



3. Orphaned Spawns Removed (319 entries)

Cross-referenced every spawn entry in monster.db against the valid sector map. Found 319 spawn entries pointing to positions in sectors that only exist in 7.72 (the 401 excluded post-7.5 sectors).

These spawns referenced creatures in underground expansions, new caves, and areas added between versions — places that simply don't exist on the 7.5 map. All 319 entries commented out with # [REMOVED-77only] prefix. Originals backed up as monster.db.bak77.



4. Orphaned Teleporters Removed (16 entries)

Analyzed all 3,708 absolute positions in the active moveuse.dat. Found 16 lines containing source or destination positions in non-existent sectors.

Teleporters/triggers added to connect to post-7.5 areas. Commented out with # [REMOVED-77only] prefix. After cleanup, all 3,708 remaining positions point to valid sectors — verified.



5. Unused Monster Files Removed (25 files)

Parsed all 159 .mon files to extract their RaceNumber, then cross-referenced with the 135 unique race IDs actually spawned on the map. Found 25 monster definitions with no active spawns:

  • Boss monsters: Orshabaal, Morgaroth, Ferumbras, Bazir, Infernatil, Apocalypse, Demodras, Dharalion, Grorlam, Fernfang, Murius, Necropharus, The Old Widow, Evil Eye, Horned Fox
  • Event/special mobs: Halloween Hare, Yellow Butterfly
  • Unused types: Serpent Spawn, Yeti, Gazer, Badger, Mimic, Slime2
  • Meta: Gamemaster, Human

All 25 files moved to mon/_unused_77/ (not deleted). Remaining: 134 active .mon files matching exactly the races spawned on the map.



6. Monster Loot Cleaned (14 entries)

Scanned all 134 active .mon loot tables for invalid items. Found and removed 14 entries in two categories:

A) Item with no 7.55 sprite (1 entry):
  • hydra.mon: (4839, 1, 9) — "a hydra egg" (ID 4839). No sprite in 7.55 Tibia.dat.

B) Wands & Rods — added in 7.6 update (13 entries):

Combat wands (for Sorcerers) and rods (for Druids) were introduced in the 7.6 update (December 12, 2005) as part of the magic system overhaul. These items have valid sprites in the 7.55 client (TypeIDs below 4402), but they did not exist as gameplay items in 7.5. Removed from loot tables of 13 monsters:

  • Beholder (quagmire rod), Dragon (wand of inferno), Efreet (wand of inferno)
  • Elf Arcanist (wand of cosmic energy), Fire Devil (volcanic rod)
  • Lizard Snake Charmer (quagmire rod + snakebite rod), Marid (tempest rod)
  • Merlkin (wand of plague), Minotaur Mage (wand of cosmic energy)
  • Orc Shaman (wand of plague), Priestess (tempest rod), Witch (volcanic rod)

All entries commented out with # [REMOVED-76] prefix. Monster summon references were also checked — 0 issues.

Note on loot authenticity: While all loot item IDs are now valid for 7.55, the loot tables themselves come from 7.72 server data. If CipSoft changed drop rates or added new drops between 7.5 and 7.72, those changes are present. We can verify item IDs exist in the client and remove known post-7.5 additions (like wands/rods), but we can't fully verify whether every remaining drop existed in the original 7.5 — that data was in server-side files nobody has.



7. NPC Cleanup (19 files modified, 9 files removed)

A) Items with no 7.55 sprite (Type > 4402):

Parsed all .npc files and .ndb behavior databases for Type=XXXX references above 4402.

Surgically cleaned (3 NPCs):
  • Elvith — removed elven poetry book sale (Type=4844). Rest of NPC intact.
  • Padreia — removed cough syrup sale (Type=4828). Rest of NPC (spell teacher) intact.
  • Uzgod — removed family brooch/dwarven pickaxe quest chain (Types 4834, 4845). The blacksmith's core trade functions remain, only the post-7.55 quest dialogue was stripped.

Fully removed (2 files → npc/_unused_77/):
  • Hairycles — entire quest chain uses post-7.55 items (whisper moss, hydra egg, witches cap mushroom, ape statue furniture packages). Quest logic too interwoven for surgical removal.
  • Explorer Society (explorer.ndb) — 25 lines across 16+ quest branches referencing post-7.55 items (butterfly hunts, plant collections, ectoplasm, spectral dress, orichalcum pearls, etc.). The @Include references in angus.npc and mortimer.npc were commented out.

B) Wand & Rod NPC system — added in 7.6 update:

Same logic as monster loot: wands and rods didn't exist as gameplay items in 7.5. The 7.72 server data includes an entire NPC ecosystem for selling, buying, and giving away first wands/rods. All of this was stripped:

Trade template databases removed (2 files → npc/_unused_77/):
  • gen-t-wands-free-s.ndb — wand/rod sell templates for free account shops
  • gen-t-wands-prem-s.ndb — wand/rod sell templates for premium shops (includes wand of inferno + tempest rod)

@Include references commented out (10 seller NPCs):
  • Alexander, Fenech, Tandros (premium wand/rod shops) + Asima (removed in 7.6 NPC cleanup below)
  • Frans, Rachel, Shiriel, Topsy, Xodet (free wand/rod shops) + Sigurd (removed in 7.6 NPC cleanup below)

Individual wand/rod lines cleaned (15 NPCs, 34 lines):
  • "First wand/rod" giveaway — Chatterbone, Etzel, Faluae, Lea, Marvik, Muriel, Myra, Padreia, Rahkem, Shalmar, Smiley, Tothdral, Ustan (free starter wand/rod via QuestValue 333)
  • Wand/rod buyback — Haroun (buys wands), Yaman (buys rods)

All entries commented out with # [REMOVED-76] prefix.

Dialog text fixes (10 NPCs, 13 fixes): After removing the wand/rod trade system, several NPCs still had "offer" and "job" dialog lines mentioning "wands" and "rods" in their text responses. Fixed in: Alexander, Fenech, Frans, Haroun, Shiriel, Tandros, Topsy, Xodet, Yaman. All remaining NPCs are fully functional for their non-wand/rod activities.

C) 7.6 NPCs removed (5 files → npc/_unused_77/):

These NPCs were added in the 7.6 update (December 12, 2005) and did not exist in 7.55:

  • Angelina — Dark Cathedral prisoner rescue (teleport quest). Entirely 7.6 content.
  • Angus — Explorer Society base in Port Hope. All quest branches are 7.6+ (QuestValue 300/320, spectral stones).
  • Mortimer — Explorer Society base in Northport. Mirror of Angus — same 7.6 quest system.
  • Asima — Magic shop in Ankrahmun. Added in 7.6 alongside Ankrahmun's magic trade expansion. Sells runes/fluids/spellbooks via standard templates.
  • Sigurd — Magic shop near Kazordoon. Added in 7.6 as brother of existing NPC Etzel. Sells runes/fluids/spellbooks via standard templates.

D) Unused NPC behavior databases (17 .ndb files → npc/_unused_77/):
  • Trade list templates not referenced by any active NPC: armor, distance weapons, fruit, gear, gems, helmets, legs, magic items, meat, music, shields, weapons (buy/sell variants), plus Christmas event and test files.

After cleanup: 331 .npc + 19 .ndb = 350 active files, zero wand/rod references, zero Type > 4402.



8. Everything Else — Verified Clean

  • houses.dat — 862 houses, all Exit/Center positions in valid sectors ✓
  • owners.dat — 530 ownership entries, all reference existing house IDs ✓
  • map.dat — 51 map markers + 2 start positions, all in valid sectors ✓
  • houseareas.dat — area definitions (structural) ✓
  • circles.dat — distance lookup table (structural) ✓
  • moveuse.dat — all 3,708 remaining absolute positions point to valid sectors ✓
  • NPC Home positions — all 331 NPCs have homes in existing sectors (0 off-map) ✓



Directory Structure

Code:
origmap/         → Active merged map (9,478 .sec) — fully 7.55-clean
origmap_75/      → Original 7.5 binary map (9,478 hex .sec) — untouched archive
origmap_77/      → Original 7.7 text map (9,874 decimal .sec) — untouched archive

dat/             → Cleaned server data (orphaned entries commented out)
dat_77/          → Original 7.7 server data (pre-cleanup archive)

mon/             → 134 active .mon files (spawned races only)
mon/_unused_77/  → 25 unused .mon files (bosses, events, unspawned)

npc/             → 331 .npc + 19 .ndb (all 7.55-compatible)
npc/_unused_77/  → 26 files (5 NPCs from 7.6, hairycles, explorer, wand templates, 17 unused .ndb)

Nothing was permanently deleted — all removed content lives in _unused_77/ subdirectories or .bak77 backup files. Everything is reversible.



9. Cross-check Against 7.6 Changelog

After cleanup, we went through the full 7.6 changelog point by point to verify nothing was missed:

Code:
7.6 Content                           Status
─────────────────────────────────────────────────────────────────────
Wands & Rods (IDs 3065-3075)          ✓ Removed from 13 monster loot tables,
                                        10 seller NPCs, 15 giveaway NPCs,
                                        2 buyback NPCs, 2 .ndb templates
7.6 NPCs (Angelina, Angus, Asima,     ✓ All 5 moved to npc/_unused_77/
  Mortimer, Sigurd)
NPC "Assistant" (Darashia)             ✓ Not present in 7.72 data — no action needed
Explorer Society quest (7.6 part)      ✓ explorer.ndb removed, Angus/Mortimer removed,
                                        DoorQuestNumber 320 zeroed out
Explorer Society quest (7.5 part)      ✓ Intact — QuestValues 311/312 (Elvith poetry),
                                        325/326 (Uzgod pickaxe) confirmed pre-7.6
Hydra Egg Quest items (ID 4839+)       ✓ Already removed (Type > 4402 threshold)
Ape City Quest items (monkey statues,  ✓ Already removed (Type > 4402 threshold)
  snake destroyer, etc.)
Key 5050 (Dark Cathedral)              ✓ Authentic 7.5 content — ChestQuestNumber 291
                                        verified in original 7.5 binary map
New map objects (anchors, bollards,    ✓ Already removed (IDs 4904-5007 in section 1)
  energy fences, ship parts)
Deeper Banuta / Hydra Hill sectors     ✓ Already excluded (sectors only in 7.72 map)
Rune NPC sales (from 7.55)            ✓ Kept — this is pre-7.6 content
Magic system changes (mlvl→level,      — Server-side mechanics, not in map/NPC data
  mana regen, spell costs)
7.7 changes (DX9, PM whitelist,        — Client/protocol only, no map data impact
  crash reports, encryption)

Every actionable piece of 7.6 content has been addressed. The remaining 7.6/7.7 changes are server-side mechanics (spell requirements, mana regeneration, rune crafting rules) and client features (DirectX 9, OpenGL, PM whitelist, connection encryption) that don't exist in map or NPC data files.



Full Cleanup Summary

Code:
Category                              Removed    Verified clean
─────────────────────────────────────────────────────────────
Map items (Type > 4402)               7,009      0 remaining
  - IDs 4403-4501 (terrain)           1,486      (cross-verified vs 7.5 binary)
  - IDs 4502-5090 (all types)         5,523      (no sprite in 7.55 Tibia.dat)
Quest: ChestQuestNumber                   0      210/210 authentic 7.5
Quest: DoorQuestNumber                    1      22/22 authentic 7.5
Quest: KeyNumber                          0      8/8 authentic 7.5
Quest: KeyholeNumber                      0      74/74 authentic 7.5
Orphaned spawns (monster.db)            319      0 remaining
Orphaned teleporters (moveuse.dat)       16      0 remaining
Unused monster files (mon/)              25      134 active
Monster loot (Type > 4402)                1      0 remaining
Monster loot (7.6 wands/rods)            13      0 remaining
NPC files (Type > 4402)               5 + 2      0 Type > 4402
NPC wand/rod system (7.6)       15 + 10 + 2      0 wand/rod refs
NPC dialog text fixes (7.6)            13      0 stale references
NPCs from 7.6 update                    5      331 active
Unused NPC behaviors (.ndb)             17      19 active
Houses off-map                           0      862 verified
Map marks off-map                        0      51 verified
NPC positions off-map                    0      331 verified
moveuse destinations off-map              0      3,708 verified

Item threshold methodology: The 7.55 Tibia.dat declares last_item_id = 4402. The conversion.lst (7.5 server item mapping) covers TypeIDs 100-4393 continuously with zero gaps. IDs 4394-4402 are "rock soil" variants that have sprites but weren't used by the 7.5 server. IDs above 4402 have no client sprite data at all. Additionally, combat wands and rods (IDs 3065-3075) have valid sprites but were added as gameplay items in the 7.6 update — these were removed from loot tables and NPC scripts separately.

The map, all server data, all NPC scripts, all monster definitions, all loot tables, and all quest attributes now reference only items, positions, and entities that exist within the 7.55 version. Quest data is verified authentic against the original 7.5 binary map.

Still pre-alpha. Feedback welcome
 
Update 3 — Full 7.55 Compatibility Cleanup: Removing Everything That Shouldn't Exist

Following up on the map merge system from Update 2. After merging the 7.5 terrain with 7.72 dynamic content, we ran a deep audit of the entire dataset — every .sec sector, every spawn, every teleporter, every NPC script, every monster loot table, and every quest attribute — to strip out anything that doesn't belong in 7.55. The merged map is now fully clean.



What was cleaned and why

The merge gave us 7.5 terrain + 7.72 gameplay content. But the 7.72 data contains things added between versions — items the 7.55 client can't render, spawn points in sectors that don't exist on the 7.5 map, teleporters leading to nowhere, NPCs selling phantom items, monster loot referencing non-existent drops, and quest attributes that were added post-7.5. All of that is now gone.

How we determined the correct item threshold:
The 7.55 Tibia.dat header declares last_item_id = 4402 — meaning the client has sprite data for TypeIDs 100-4402 only. conversion.lst (the 7.5 server's item mapping table) covers TypeIDs 100-4393 with zero gaps. Items 4394-4402 exist in the client but aren't referenced by the 7.5 server — they're harmless "rock soil" variants. Anything above 4402 has no client sprite and would render as invisible/broken. That's our hard cutoff.



1. Invalid Items Removed from Map (7,009 instances)

Scanned all 9,478 sectors (~8 million item instances). Found and removed 7,009 items with TypeIDs above 4402 — items that have no sprite data in the 7.55 Tibia.dat and would render as invisible/broken objects. Cross-verified against the original 7.5 binary map: zero of these items exist there — they all came from the 7.72 layer.

Breakdown by category:
  • Flat roof tiles (IDs 5048-5054): ~3,882 instances — 7.7+ roof tiles CipSoft added for building tops.
  • Ship/port decorations (IDs 4904-5007): ~1,580 instances — ship cabin walls, railings, masts, sails, steering wheels, rudder blades, hawsers, bollards, anchors, ventilation grilles.
  • Mountain/terrain variants (IDs 4403-4468): ~1,486 instances — new rock soil, rocks, and mountain tile variants added post-7.55. Found across 333 sectors.
  • Ground tile variants (IDs 4515-4553, 4749-4758): ~47 instances — new grass, gravel, and sand variants.
  • Miscellaneous: red carpets (4860-4862), skull variants (5015/5017), magic forcefield (5022), panda teddy (5080), new door types (5082/5084) — ~14 instances.

After cleanup: 0 items with ID > 4402 remain on the map. Every single item is now renderable by the 7.55 client.



2. Quest Attributes — Verified Against Original 7.5 Binary Map

This was the big question: are the quest numbers on the merged map actually authentic 7.5 data, or did 7.72 contamination sneak in?

We parsed both the original 7.5 binary map (origmap_75/) and the merged map, extracting every quest-related attribute from every item on every tile. Then compared them:

Code:
Attribute              Original 7.5    Merged map    New (post-7.5)    Action
──────────────────────────────────────────────────────────────────────────────
ChestQuestNumber            210            210              0           ✓ clean
DoorQuestNumber              22             23              1           removed
KeyNumber                     8              8              0           ✓ clean
KeyholeNumber                74             74              0           ✓ clean

All 210 ChestQuestNumbers are 100% authentic from the original 7.5 binary map. Zero added, zero lost. The chest quests survived the merge process perfectly — they come from the 7.5 structural layer (chests are STATIC items with Container+Unmove flags), so the merger preserved them from the 7.5 source as intended.

Same story for KeyNumbers (8/8) and KeyholeNumbers (74/74) — all identical to the 7.5 original.

The one exception: DoorQuestNumber 320 — a quest door at position (32500, 31622, 6) that was added after 7.5. The quest attributes (DQ=320, DQV=5) were zeroed out, turning it back into a normal door. All 22 original 7.5 DoorQuestNumbers remain intact.



3. Orphaned Spawns Removed (319 entries)

Cross-referenced every spawn entry in monster.db against the valid sector map. Found 319 spawn entries pointing to positions in sectors that only exist in 7.72 (the 401 excluded post-7.5 sectors).

These spawns referenced creatures in underground expansions, new caves, and areas added between versions — places that simply don't exist on the 7.5 map. All 319 entries commented out with # [REMOVED-77only] prefix. Originals backed up as monster.db.bak77.



4. Orphaned Teleporters Removed (16 entries)

Analyzed all 3,708 absolute positions in the active moveuse.dat. Found 16 lines containing source or destination positions in non-existent sectors.

Teleporters/triggers added to connect to post-7.5 areas. Commented out with # [REMOVED-77only] prefix. After cleanup, all 3,708 remaining positions point to valid sectors — verified.



5. Unused Monster Files Removed (25 files)

Parsed all 159 .mon files to extract their RaceNumber, then cross-referenced with the 135 unique race IDs actually spawned on the map. Found 25 monster definitions with no active spawns:

  • Boss monsters: Orshabaal, Morgaroth, Ferumbras, Bazir, Infernatil, Apocalypse, Demodras, Dharalion, Grorlam, Fernfang, Murius, Necropharus, The Old Widow, Evil Eye, Horned Fox
  • Event/special mobs: Halloween Hare, Yellow Butterfly
  • Unused types: Serpent Spawn, Yeti, Gazer, Badger, Mimic, Slime2
  • Meta: Gamemaster, Human

All 25 files moved to mon/_unused_77/ (not deleted). Remaining: 134 active .mon files matching exactly the races spawned on the map.



6. Monster Loot Cleaned (14 entries)

Scanned all 134 active .mon loot tables for invalid items. Found and removed 14 entries in two categories:

A) Item with no 7.55 sprite (1 entry):
  • hydra.mon: (4839, 1, 9) — "a hydra egg" (ID 4839). No sprite in 7.55 Tibia.dat.

B) Wands & Rods — added in 7.6 update (13 entries):

Combat wands (for Sorcerers) and rods (for Druids) were introduced in the 7.6 update (December 12, 2005) as part of the magic system overhaul. These items have valid sprites in the 7.55 client (TypeIDs below 4402), but they did not exist as gameplay items in 7.5. Removed from loot tables of 13 monsters:

  • Beholder (quagmire rod), Dragon (wand of inferno), Efreet (wand of inferno)
  • Elf Arcanist (wand of cosmic energy), Fire Devil (volcanic rod)
  • Lizard Snake Charmer (quagmire rod + snakebite rod), Marid (tempest rod)
  • Merlkin (wand of plague), Minotaur Mage (wand of cosmic energy)
  • Orc Shaman (wand of plague), Priestess (tempest rod), Witch (volcanic rod)

All entries commented out with # [REMOVED-76] prefix. Monster summon references were also checked — 0 issues.

Note on loot authenticity: While all loot item IDs are now valid for 7.55, the loot tables themselves come from 7.72 server data. If CipSoft changed drop rates or added new drops between 7.5 and 7.72, those changes are present. We can verify item IDs exist in the client and remove known post-7.5 additions (like wands/rods), but we can't fully verify whether every remaining drop existed in the original 7.5 — that data was in server-side files nobody has.



7. NPC Cleanup (19 files modified, 9 files removed)

A) Items with no 7.55 sprite (Type > 4402):

Parsed all .npc files and .ndb behavior databases for Type=XXXX references above 4402.

Surgically cleaned (3 NPCs):
  • Elvith — removed elven poetry book sale (Type=4844). Rest of NPC intact.
  • Padreia — removed cough syrup sale (Type=4828). Rest of NPC (spell teacher) intact.
  • Uzgod — removed family brooch/dwarven pickaxe quest chain (Types 4834, 4845). The blacksmith's core trade functions remain, only the post-7.55 quest dialogue was stripped.

Fully removed (2 files → npc/_unused_77/):
  • Hairycles — entire quest chain uses post-7.55 items (whisper moss, hydra egg, witches cap mushroom, ape statue furniture packages). Quest logic too interwoven for surgical removal.
  • Explorer Society (explorer.ndb) — 25 lines across 16+ quest branches referencing post-7.55 items (butterfly hunts, plant collections, ectoplasm, spectral dress, orichalcum pearls, etc.). The @Include references in angus.npc and mortimer.npc were commented out.

B) Wand & Rod NPC system — added in 7.6 update:

Same logic as monster loot: wands and rods didn't exist as gameplay items in 7.5. The 7.72 server data includes an entire NPC ecosystem for selling, buying, and giving away first wands/rods. All of this was stripped:

Trade template databases removed (2 files → npc/_unused_77/):
  • gen-t-wands-free-s.ndb — wand/rod sell templates for free account shops
  • gen-t-wands-prem-s.ndb — wand/rod sell templates for premium shops (includes wand of inferno + tempest rod)

@Include references commented out (10 seller NPCs):
  • Alexander, Fenech, Tandros (premium wand/rod shops) + Asima (removed in 7.6 NPC cleanup below)
  • Frans, Rachel, Shiriel, Topsy, Xodet (free wand/rod shops) + Sigurd (removed in 7.6 NPC cleanup below)

Individual wand/rod lines cleaned (15 NPCs, 34 lines):
  • "First wand/rod" giveaway — Chatterbone, Etzel, Faluae, Lea, Marvik, Muriel, Myra, Padreia, Rahkem, Shalmar, Smiley, Tothdral, Ustan (free starter wand/rod via QuestValue 333)
  • Wand/rod buyback — Haroun (buys wands), Yaman (buys rods)

All entries commented out with # [REMOVED-76] prefix.

Dialog text fixes (10 NPCs, 13 fixes): After removing the wand/rod trade system, several NPCs still had "offer" and "job" dialog lines mentioning "wands" and "rods" in their text responses. Fixed in: Alexander, Fenech, Frans, Haroun, Shiriel, Tandros, Topsy, Xodet, Yaman. All remaining NPCs are fully functional for their non-wand/rod activities.

C) 7.6 NPCs removed (5 files → npc/_unused_77/):

These NPCs were added in the 7.6 update (December 12, 2005) and did not exist in 7.55:

  • Angelina — Dark Cathedral prisoner rescue (teleport quest). Entirely 7.6 content.
  • Angus — Explorer Society base in Port Hope. All quest branches are 7.6+ (QuestValue 300/320, spectral stones).
  • Mortimer — Explorer Society base in Northport. Mirror of Angus — same 7.6 quest system.
  • Asima — Magic shop in Ankrahmun. Added in 7.6 alongside Ankrahmun's magic trade expansion. Sells runes/fluids/spellbooks via standard templates.
  • Sigurd — Magic shop near Kazordoon. Added in 7.6 as brother of existing NPC Etzel. Sells runes/fluids/spellbooks via standard templates.

D) Unused NPC behavior databases (17 .ndb files → npc/_unused_77/):
  • Trade list templates not referenced by any active NPC: armor, distance weapons, fruit, gear, gems, helmets, legs, magic items, meat, music, shields, weapons (buy/sell variants), plus Christmas event and test files.

After cleanup: 331 .npc + 19 .ndb = 350 active files, zero wand/rod references, zero Type > 4402.



8. Everything Else — Verified Clean

  • houses.dat — 862 houses, all Exit/Center positions in valid sectors ✓
  • owners.dat — 530 ownership entries, all reference existing house IDs ✓
  • map.dat — 51 map markers + 2 start positions, all in valid sectors ✓
  • houseareas.dat — area definitions (structural) ✓
  • circles.dat — distance lookup table (structural) ✓
  • moveuse.dat — all 3,708 remaining absolute positions point to valid sectors ✓
  • NPC Home positions — all 331 NPCs have homes in existing sectors (0 off-map) ✓



Directory Structure

Code:
origmap/         → Active merged map (9,478 .sec) — fully 7.55-clean
origmap_75/      → Original 7.5 binary map (9,478 hex .sec) — untouched archive
origmap_77/      → Original 7.7 text map (9,874 decimal .sec) — untouched archive

dat/             → Cleaned server data (orphaned entries commented out)
dat_77/          → Original 7.7 server data (pre-cleanup archive)

mon/             → 134 active .mon files (spawned races only)
mon/_unused_77/  → 25 unused .mon files (bosses, events, unspawned)

npc/             → 331 .npc + 19 .ndb (all 7.55-compatible)
npc/_unused_77/  → 26 files (5 NPCs from 7.6, hairycles, explorer, wand templates, 17 unused .ndb)

Nothing was permanently deleted — all removed content lives in _unused_77/ subdirectories or .bak77 backup files. Everything is reversible.



9. Cross-check Against 7.6 Changelog

After cleanup, we went through the full 7.6 changelog point by point to verify nothing was missed:

Code:
7.6 Content                           Status
─────────────────────────────────────────────────────────────────────
Wands & Rods (IDs 3065-3075)          ✓ Removed from 13 monster loot tables,
                                        10 seller NPCs, 15 giveaway NPCs,
                                        2 buyback NPCs, 2 .ndb templates
7.6 NPCs (Angelina, Angus, Asima,     ✓ All 5 moved to npc/_unused_77/
  Mortimer, Sigurd)
NPC "Assistant" (Darashia)             ✓ Not present in 7.72 data — no action needed
Explorer Society quest (7.6 part)      ✓ explorer.ndb removed, Angus/Mortimer removed,
                                        DoorQuestNumber 320 zeroed out
Explorer Society quest (7.5 part)      ✓ Intact — QuestValues 311/312 (Elvith poetry),
                                        325/326 (Uzgod pickaxe) confirmed pre-7.6
Hydra Egg Quest items (ID 4839+)       ✓ Already removed (Type > 4402 threshold)
Ape City Quest items (monkey statues,  ✓ Already removed (Type > 4402 threshold)
  snake destroyer, etc.)
Key 5050 (Dark Cathedral)              ✓ Authentic 7.5 content — ChestQuestNumber 291
                                        verified in original 7.5 binary map
New map objects (anchors, bollards,    ✓ Already removed (IDs 4904-5007 in section 1)
  energy fences, ship parts)
Deeper Banuta / Hydra Hill sectors     ✓ Already excluded (sectors only in 7.72 map)
Rune NPC sales (from 7.55)            ✓ Kept — this is pre-7.6 content
Magic system changes (mlvl→level,      — Server-side mechanics, not in map/NPC data
  mana regen, spell costs)
7.7 changes (DX9, PM whitelist,        — Client/protocol only, no map data impact
  crash reports, encryption)

Every actionable piece of 7.6 content has been addressed. The remaining 7.6/7.7 changes are server-side mechanics (spell requirements, mana regeneration, rune crafting rules) and client features (DirectX 9, OpenGL, PM whitelist, connection encryption) that don't exist in map or NPC data files.



Full Cleanup Summary

Code:
Category                              Removed    Verified clean
─────────────────────────────────────────────────────────────
Map items (Type > 4402)               7,009      0 remaining
  - IDs 4403-4501 (terrain)           1,486      (cross-verified vs 7.5 binary)
  - IDs 4502-5090 (all types)         5,523      (no sprite in 7.55 Tibia.dat)
Quest: ChestQuestNumber                   0      210/210 authentic 7.5
Quest: DoorQuestNumber                    1      22/22 authentic 7.5
Quest: KeyNumber                          0      8/8 authentic 7.5
Quest: KeyholeNumber                      0      74/74 authentic 7.5
Orphaned spawns (monster.db)            319      0 remaining
Orphaned teleporters (moveuse.dat)       16      0 remaining
Unused monster files (mon/)              25      134 active
Monster loot (Type > 4402)                1      0 remaining
Monster loot (7.6 wands/rods)            13      0 remaining
NPC files (Type > 4402)               5 + 2      0 Type > 4402
NPC wand/rod system (7.6)       15 + 10 + 2      0 wand/rod refs
NPC dialog text fixes (7.6)            13      0 stale references
NPCs from 7.6 update                    5      331 active
Unused NPC behaviors (.ndb)             17      19 active
Houses off-map                           0      862 verified
Map marks off-map                        0      51 verified
NPC positions off-map                    0      331 verified
moveuse destinations off-map              0      3,708 verified

Item threshold methodology: The 7.55 Tibia.dat declares last_item_id = 4402. The conversion.lst (7.5 server item mapping) covers TypeIDs 100-4393 continuously with zero gaps. IDs 4394-4402 are "rock soil" variants that have sprites but weren't used by the 7.5 server. IDs above 4402 have no client sprite data at all. Additionally, combat wands and rods (IDs 3065-3075) have valid sprites but were added as gameplay items in the 7.6 update — these were removed from loot tables and NPC scripts separately.

The map, all server data, all NPC scripts, all monster definitions, all loot tables, and all quest attributes now reference only items, positions, and entities that exist within the 7.55 version. Quest data is verified authentic against the original 7.5 binary map.

Still pre-alpha. Feedback welcome
I think you are missing old Aruda sprite from 7.5. Iirc this npc changed sprite when new graphics came into scene. Probably we are missing some more stuff im on cellphone not at home but that is probably one change i think you didnt addressed(?)
 
Update 4 — Game Server Downgrade to 7.55 + Full Map Conversion Pipeline

After getting the map editor and data cleanup in order (Update 3), the next logical step was to actually run server. Here's what happened.
* * *

The Server

I took fusion32's Tibia game server — a C++ reimplementation of the original CipSoft 7.70/7.72 engine — and downgraded it to work with the 7.55 protocol. The codebase already had some #if TIBIA755 preprocessor guards from earlier experiments, but most of the critical subsystems needed manual adjustments:

  • Protocol: 7.55 uses plaintext (no XTEA/RSA encryption), different packet structures, different creature data format
  • QueryManager: Re-enabled connection to fusion32's tibia-querymanager (SQLite-based) — had to fix the password handshake (the game server applies a DisguisePassword() XOR transform before sending, so the QM config needs the plaintext password, not the disguised one from .tibia)
  • Login server: Wrote a minimal Python login server for the 7.55 plaintext protocol (port 7171 → character list → game server on port 7172)

The whole thing runs in Docker (Ubuntu 22.04, g++ build) with the QueryManager launched alongside the game process.

* * *

Map Conversion: 7.5 Binary → 7.7 Text

The original map is in CipSoft 7.5 binary .sec format (hex filenames, binary tile streams with group/number item encoding). The game server expects 7.7 text .sec format (decimal filenames like XXXX-YYYY-ZZ.sec, human-readable Content={...} syntax).

My map editor's parsers (sec_parser_75.py + sec_parser.py) handle both formats, so I wrote a batch conversion script:

  • 9,478 sectors converted, 0 errors
  • All 3,513 unique TypeIDs verified within the 7.55 range (max found: 4393, client limit: 4402)
  • Round-trip fidelity: 99.8% byte-identical with original binary data

* * *

The Tricky Bug

After the first conversion, 87 sectors failed to load with unknown attribute errors. The C++ server parser was choking on sign/book text containing unescaped quotes:

Code:
String="house "Great Willow 1c" rent..."

The parser would see " after house , think the string ended, and then try to parse Great as an attribute name → crash. Fix: proper escape handling (\", \\) in the serializer. After that — zero parse errors across all 9,478 sectors.

* * *

Current Status

Everything boots clean:

  • 323 NPCs loaded (Frodo, Willard, Aruda, all the classics...)
  • Monsters spawning normally (Dragon Lords, Orcs, Beholders, Amazons...)
  • QueryManager authorized and connected
  • 0 map parse errors
 

Attachments

  • Screenshot_2041.webp
    Screenshot_2041.webp
    374.7 KB · Views: 62 · VirusTotal
  • Screenshot_2043.webp
    Screenshot_2043.webp
    243.1 KB · Views: 63 · VirusTotal
Last edited:
Update 4 — Game Server Downgrade to 7.55 + Full Map Conversion Pipeline

After getting the map editor and data cleanup in order (Update 3), the next logical step was to actually run server. Here's what happened.
* * *

The Server


I took fusion32's Tibia game server — a C++ reimplementation of the original CipSoft 7.70/7.72 engine — and downgraded it to work with the 7.55 protocol. The codebase already had some #if TIBIA755 preprocessor guards from earlier experiments, but most of the critical subsystems needed manual adjustments:

  • Protocol: 7.55 uses plaintext (no XTEA/RSA encryption), different packet structures, different creature data format
  • QueryManager: Re-enabled connection to fusion32's tibia-querymanager (SQLite-based) — had to fix the password handshake (the game server applies a DisguisePassword() XOR transform before sending, so the QM config needs the plaintext password, not the disguised one from .tibia)
  • Login server: Wrote a minimal Python login server for the 7.55 plaintext protocol (port 7171 → character list → game server on port 7172)

The whole thing runs in Docker (Ubuntu 22.04, g++ build) with the QueryManager launched alongside the game process.

* * *

Map Conversion: 7.5 Binary → 7.7 Text


The original map is in CipSoft 7.5 binary .sec format (hex filenames, binary tile streams with group/number item encoding). The game server expects 7.7 text .sec format (decimal filenames like XXXX-YYYY-ZZ.sec, human-readable Content={...} syntax).

My map editor's parsers (sec_parser_75.py + sec_parser.py) handle both formats, so I wrote a batch conversion script:

  • 9,478 sectors converted, 0 errors
  • All 3,513 unique TypeIDs verified within the 7.55 range (max found: 4393, client limit: 4402)
  • Round-trip fidelity: 99.8% byte-identical with original binary data

* * *

The Tricky Bug


After the first conversion, 87 sectors failed to load with unknown attribute errors. The C++ server parser was choking on sign/book text containing unescaped quotes:

Code:
String="house "Great Willow 1c" rent..."

The parser would see " after house , think the string ended, and then try to parse Great as an attribute name → crash. Fix: proper escape handling (\", \\) in the serializer. After that — zero parse errors across all 9,478 sectors.

* * *

Current Status


Everything boots clean:

  • 323 NPCs loaded (Frodo, Willard, Aruda, all the classics...)
  • Monsters spawning normally (Dragon Lords, Orcs, Beholders, Amazons...)
  • QueryManager authorized and connected
  • 0 map parse errors
Any chance to get the otbm from 7.5 originmap approach? I also think you would need to manually replace the spawns from darashia ghost ship. Its z floor spawn changes from 7.5 to 7.72.
 
NPC File z: 6 → 7
Captain Bluebear captain1.npc
Captain Greyhound captain2.npc
Captain Seagull captain3.npc
Captain Seahorse captain4.npc
Captain Fearless captain5.npc
Petros captain6.npc
Captain Sinbeard captain7.npc
Captain Jack ferrymanjack.npc
Pemaret pemaret.npc

Yes, this needs to be changed a bit, because when using travel in ships, the spawn is often a level higher.

Sorry, but my editor does not support the otbm format.
 
I found something interesting while trying to convert RME to load .sec files. Basically remaking RME so it loads .sec, houses.dat, mon, raids, object.srv, etc.,

One thing I’d like to mention is that there are two houses that were bugged for me, and I couldn’t figure out why until I found a # BUGGED COORDINATES comment in houses.dat. These are the houses "Bamboo Fortress" and "Shark Manor".

So when you parse those, keep in mind that they exist :) (if you ever decide to implement house creation / editing in your mapeditor.
 
Back
Top