Hi everybody,
I'm trying to create a plugin for ShootMania and I want to generate visual elements like markers, lines, ... but it doesn't seems to be possible in the map editor.
Does someone know how to create markers, lines,... in the track editor ?
Is it possible ?
EDIT : At least, a solution for markers would be great. If you know anything else that react like a ghost element and can be placed on a map. Don't hesitate to answer to my topic.
[ManiaScript] Display markers in map editor ?
Moderator: English Moderator
-
- Posts: 1256
- Joined: 06 Mar 2013, 16:12
- Manialink: explore
- Location: Vendée | France
- Contact:
- Nerpson
- Translator
- Posts: 1554
- Joined: 27 Sep 2013, 18:02
- Manialink: nerpson
- Location: France
- Contact:
Re: [ManiaScript] Display markers in map editor ?
After a deep search in the documentation, I found nothing that allows you to display markers. The only case where markers are displayed in the map editor is when you set the anchor types, like Goals, Starts, and this thing is only available in a MapType script.
Otherwise, you can create something that displays some information in a manialink when you point specific blocks.

Otherwise, you can create something that displays some information in a manialink when you point specific blocks.

-
- Posts: 1256
- Joined: 06 Mar 2013, 16:12
- Manialink: explore
- Location: Vendée | France
- Contact:
Re: [ManiaScript] Display markers in map editor ?
Ty Nerpson
Do you know if it's possible to do something like this with ManiaScript ?

If not, it's not a big deal. I'll place a block instead.

Do you know if it's possible to do something like this with ManiaScript ?

If not, it's not a big deal. I'll place a block instead.
Re: [ManiaScript] Display markers in map editor ?
You could set Anchor.Tag, then all you set in this property is visible as marker in editor, this works with items too 
(only tested on ShootMania, 3 years ago)
This is a portion of code i wrote for that.
Hope this help.

(only tested on ShootMania, 3 years ago)
This is a portion of code i wrote for that.
Hope this help.
Code: Select all
// Rename all tags/markers in DefaultTag: impossible to use Hud3dmarkers with position of anchors in editor
// Bug with MLEncode ?
Void RefreshTags()
{
declare metadata Text[Text][] MapQuests for Map;
declare metadata Text[Text][] MapCharacters for Map; //< Value[PropertyName][CharacterId]
foreach(Anchor in AnchorData)
{
declare metadata Text Name for Anchor;
declare metadata Integer EId for Anchor;
declare metadata Integer QuestId for Anchor;
Anchor.Tag = "#"^EId^": ";
if (MapQuests.existskey(QuestId)) Anchor.Tag ^= MapQuests[QuestId]["Name"];
else Anchor.Tag ^= None();
// Add selected characters name after quest name
declare metadata Integer[] CharacterId for Anchor;
// if all characters associated to this anchor
if (CharacterId.count == MapCharacters.count)
{
if (Anchor.DefaultTag == "Spawn") Anchor.Tag ^= " "^All();
else Anchor.Tag ^= " "^Anyone();
}
else // Display Characters Name
{
foreach(CId in CharacterId)
{
Anchor.Tag ^= " $z$o$s$000" ^ CM::Name(CId);
}
}
}
}
-
- Posts: 1256
- Joined: 06 Mar 2013, 16:12
- Manialink: explore
- Location: Vendée | France
- Contact:
Re: [ManiaScript] Display markers in map editor ?
Ty spaii
I'll try your code. I'll understand it first because I don't understand how can I place (using position x, y, z) the markers.
After setting Anchor.Tag, How can I place it somewhere in the map ?
EDIT :
I tried and edited the code but I think your code is for markers over poles or spawns.

I'll try your code. I'll understand it first because I don't understand how can I place (using position x, y, z) the markers.
After setting Anchor.Tag, How can I place it somewhere in the map ?
EDIT :
I tried and edited the code but I think your code is for markers over poles or spawns.
- Nerpson
- Translator
- Posts: 1554
- Joined: 27 Sep 2013, 18:02
- Manialink: nerpson
- Location: France
- Contact:
Re: [ManiaScript] Display markers in map editor ?
Re: [ManiaScript] Display markers in map editor ?
As Nerpson says, it's clearly not possible to place markers yourself in X Y Z position.
1. Add a goal, spawn or item (or anything else that accept AnchorData), on map.
2. Switch CEditorPlugin::PlaceMode to BlockProperty in script.
3. You will see markers you named in Anchor.Tag property
1. Add a goal, spawn or item (or anything else that accept AnchorData), on map.
2. Switch CEditorPlugin::PlaceMode to BlockProperty in script.
3. You will see markers you named in Anchor.Tag property
-
- Posts: 1256
- Joined: 06 Mar 2013, 16:12
- Manialink: explore
- Location: Vendée | France
- Contact:
Re: [ManiaScript] Display markers in map editor ?
Thank you both for your help
I finally used the selection.

I finally used the selection.
Who is online
Users browsing this forum: No registered users and 5 guests