Skip to content

Current questions and answers regarding the map editor.

User Avatar
#5148
Auto-translated
}{0TT@6bI4
Overall, it's quite a few, and it's very good for a start! This will be your first map with scripts?
Firstly, I think it's the best way to fully understand and use them. :smile15:
Secondly, the map is not yet finished.
Thirdly, I think you can use much more scripts in non-Multiplayer maps (except for Arenas). And it doesn't make much sense to stuff a Multiplayer map with a ton of scripts.
Fourthly, you can say that this is generally the first map:D, because until recently I didn't create maps and didn't even think about maps.
Fifthly, thank you for your help!:smile14:
And the saddest thing is that testing scripts in a Multiplayer map takes a lot of time and is frustrating. Because you have to restart everything 100 times. (

Added after 8 minutes
For the future, I wanted to ask. What is the difference when creating a scenario and a Multiplayer map? (I read something about it briefly... but I don't remember anymore.)

Added after 14 minutes
Oh... time wasted, and the result didn't bring the desired effect...
function teleport1(hero)
Tile = IsTilePassable(41, 86, 1);
MessageBoxForPlayers(GetPlayerFilter(GetCurrentPlayer()),"/Maps/RMG/515474A1-8A71-43BF-80ED-90E00B05311A/message.26.txt");
sleep(5);
if Tile == 1

then
SetObjectPosition(hero, 41, 86, 1); --40,84можно
print("проверка прошла ",Tile);
else SetObjectPosition(hero, 40, 84, 1);
end;
SetObjectEnabled("Message", nil)
end;
Trigger(4, "Message", "teleport1")
IsTilePassable(41, 86, 1); - returns 1 a) even if the hero is initially on that tile b) even if the hero is teleported to that tile.

Added after 3 minutes
Returns 1 if the tile at (X, Y) on the surface (Floor_ID = 0) or underground (Floor_ID = 1) is passable, or "zero" if it is blocked. It takes the mask into account, but ignores temporary blockades (e.g., a stack of monsters, a player hero, etc.).
><

Added after 1 minute
I'll have to write another workaround... why couldn't they make IsTilePassable more functional?