Map Annotations (custom levels)

SN.WolfSN.Wolf Join Date: 2010-03-29 Member: 71115Members
<div class="IPBDescription">^</div>As a few of us where messing around bug hunting in my level it was discovered map annotations work in custom maps. Where is that information stored?

Would be cool to be able to view it like UWE does as that would help a lot and wouldn't require one to break out a note pad while running through the map and taking notes.

Anyway for custom map builders to get full use of this wonderful tool to it's fullest intent?

Comments

  • LazerLazer Join Date: 2003-03-11 Member: 14406Members, Contributor, Constellation, NS2 Playtester
    Good question. I would like to know as well since I am starting to get fairly close to testing my map and would like to take advantage of this feature. From what I can tell by the LUA, annotations are being stored in a database by map name, build number, user info, and with the location and comments left. Data is transferred to and from the game through web request, which means I could write a tool to do the reverse for lookup outside the game (such as while mapping). Would anyone like me to make this tool or does one exist?
  • TigTig Join Date: 2010-05-08 Member: 71674Members, Reinforced - Shadow, WC 2013 - Silver
    <!--quoteo(post=1839526:date=Apr 1 2011, 09:52 AM:name=Lazer)--><div class='quotetop'>QUOTE (Lazer @ Apr 1 2011, 09:52 AM) <a href="index.php?act=findpost&pid=1839526"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Good question. I would like to know as well since I am starting to get fairly close to testing my map and would like to take advantage of this feature. From what I can tell by the LUA, annotations are being stored in a database by map name, build number, user info, and with the location and comments left. Data is transferred to and from the game through web request, which means I could write a tool to do the reverse for lookup outside the game (such as while mapping). Would anyone like me to make this tool or does one exist?<!--QuoteEnd--></div><!--QuoteEEnd-->

    im getting relatively close to testing as well. write the tool, that would be very useful.
  • LazerLazer Join Date: 2003-03-11 Member: 14406Members, Contributor, Constellation, NS2 Playtester
    Ok sure I will write the tool and have it up on my web host in a bit for others to try. I've figured out how to reverse engineer the web requests to show in a browser so I will write a web app that will let people enter a map name and view annotations by area. Maybe the devs will have use for this too? I could write it as an executable to download and use locally but figured a web app is a little more user friendly?
  • SgtBarlowSgtBarlow Level Designer Join Date: 2003-11-13 Member: 22749Members, NS2 Developer
    I havent finnished my annotation viewer because there is amp extents orientation bug in the game that needs fixing.

    Maps that arent square pose the obvious problem, the result is your markers wont appear in the correct position unless the level your viewing is near totaly square like Tram & Rockdown
  • FehaFeha Join Date: 2006-11-16 Member: 58633Members
    Make it a web app, but make sure its user friendly with filtering and all ;)

    how well would it handle the 3d aspect of the map btw? Would it only be able to put the annotations at accordingly minimap locations, or would it be able to sort off display the depth?.
    Maybe by having sideways minimaps uploaded aswell, or by letting player adjust the height relation between annotations and the minimap, or how about several layers of top down view minimap?
    This assumes mappers will be able to upload minimaps to the srv to see the results in a good way, but maybe you just let players dl some file that they can put in ns2 and then is read when they enable annotations ingame?

    I doubt you will use a real 3d engine displaying .level files :P
  • ThaldarinThaldarin Alonzi&#33; Join Date: 2003-07-15 Member: 18173Members, Constellation
    <!--quoteo(post=1839544:date=Apr 1 2011, 05:40 PM:name=SgtBarlow)--><div class='quotetop'>QUOTE (SgtBarlow @ Apr 1 2011, 05:40 PM) <a href="index.php?act=findpost&pid=1839544"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I havent finnished my annotation viewer because there is amp extents orientation bug in the game that needs fixing.

    Maps that arent square pose the obvious problem, the result is your markers wont appear in the correct position unless the level your viewing is near totaly square like Tram & Rockdown<!--QuoteEnd--></div><!--QuoteEEnd-->

    Does it define it by minimapextents, location or actual geometry? As for testing purposes, making location or minimapextents to a total square wouldn't be the end of the world.
  • Evil_bOb1Evil_bOb1 Join Date: 2002-07-13 Member: 938Members, Squad Five Blue
    edited April 2011
    edit: like thaldarin says.

    [Make a square minimap_extent (on the x, z plane) for temporary solution. It works for the minimap, I guess it should work for annotations. The square extents also avoids proportion issues when rendering the minimap.]
  • SgtBarlowSgtBarlow Level Designer Join Date: 2003-11-13 Member: 22749Members, NS2 Developer
    edited April 2011
    The minimap extent entity is used as refrance for the levels center point of origin to find out how far it is away it is from 0,0,0 so we can create an offset value to remap from 0,0 in the center of a users screen on a webpage and apply the offset to stored annotations when we download them. Plus the extent size is used to detrmine if the overview has been scaled down if it is a very large level so then the amount of overhead from x,y also needs summed into the annotations xy coords before they are mapped out on a canvas.

    They are still displayed in the wrong position even if I square it off by using the largest size for both x,y because it screws up the scale for one of the axis.


    I have not had a look into and work around yet, I am sure a work around had to be applied to the in game minimap because I noticed a point in the code where x,z and z,y cross over.
    I think this has appened because Max/Charlie used one XYZ convention Brian used another.
    I think Brian used X = Horizontal, Y = Verticle and Z = Depth compared to X = Horzontal, Z = Verticle and Y = Depth, Something like that.

    I like the fist one because its what Blender uses or are a web programmer too... X = Horizontal, Y = Verticle then Z-Index cotrols how close/far something is, aka whats rendered over the top of what.
  • LazerLazer Join Date: 2003-03-11 Member: 14406Members, Contributor, Constellation, NS2 Playtester
    edited April 2011
    Ok it's written and up :)

    <a href="http://devin-afshin.com/ns2_annotations.aspx" target="_blank">http://devin-afshin.com/ns2_annotations.aspx</a>

    I was going to try to parse using the json version of the output but it was easy enough to write my own loop for it. I believe all annotations for any maps should load from that.

    EDIT: Would like to overlay the locations over a minimap but with what barlow said I guess not possible right now?
  • TigTig Join Date: 2010-05-08 Member: 71674Members, Reinforced - Shadow, WC 2013 - Silver
    edited April 2011
    <!--quoteo(post=1839591:date=Apr 1 2011, 06:47 PM:name=Lazer)--><div class='quotetop'>QUOTE (Lazer @ Apr 1 2011, 06:47 PM) <a href="index.php?act=findpost&pid=1839591"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Ok it's written and up :)

    <a href="http://devin-afshin.com/ns2_annotations.aspx" target="_blank">http://devin-afshin.com/ns2_annotations.aspx</a>

    I was going to try to parse using the json version of the output but it was easy enough to write my own loop for it. I believe all annotations for any maps should load from that.

    EDIT: Would like to overlay the locations over a minimap but with what barlow said I guess not possible right now?<!--QuoteEnd--></div><!--QuoteEEnd-->

    NOICE! you sir, get waffles (#)(#)(#)(#)

    edit: added your link to my signature quicklinks :)
  • FehaFeha Join Date: 2006-11-16 Member: 58633Members
    edited April 2011
    Well it should be possible for you to overlay the annotations with the map, if you allow users to upload an image of their minimap and the bounds of the map.

    I think the best way to handle depths though, would be something like colors of the dot (and you hover to see annotation, and click to filter out) indicating its percentage of the depth bounds you told it the map have, and maybe 1 color to say that its outside, and another to say that its outside in other direction.

    Maybe save those images ppl uploaded, and let them select presets from a dropdown box, and edit if they got password they inputed when they saved it first time.
    The official maps would obviouslt be an exception.

    EDIT:
    DAMN its late (well not rly, but I intended to go to bed around 25 am, and its 27 am now) :P
  • SN.WolfSN.Wolf Join Date: 2010-03-29 Member: 71115Members
    This is a great start to something very useful, Thanks for this!!

    I find myself running the game in one monitor to see annotations and the editor in the other repairing issues.....so laggy when i do that.
  • LazerLazer Join Date: 2003-03-11 Member: 14406Members, Contributor, Constellation, NS2 Playtester
    I've updated the annotations viewer online to provide a minimap with numbered overlays. Right now the only minimaps I've uploaded are for tram and rockdown. The only issue is map_extends not working correctly so I had to write my own custom scaling structure and use a switch to choose based on the map.

    If you are a mapper who would like to use this you may send me an overview image of your map and I can add it in. Also because of the map extends I would recommend leaving an annotation in each room so I can get scaling to set correctly.
  • SN.WolfSN.Wolf Join Date: 2010-03-29 Member: 71115Members
    That's great!!
    I should be ready in a few days to release the next test build of one of my levels, I'll PM you the Overview after i rebuild it to match the level when i release.
  • Kouji_SanKouji_San Sr. Hινε Uρкεερεг - EUPT Deputy The Netherlands Join Date: 2003-05-13 Member: 16271Members, NS2 Playtester, Squad Five Blue
    edited May 2011
    @Lazer: The minimap offset is wrong for rockdown currently (might have something to do with is being weirdly positioned ingame for the commander mode as well

    <!--quoteo--><div class='quotetop'>QUOTE </div><div class='quotemain'><!--quotec-->(1) [user] Coordinates(xyz): (93.9, 8.83, 16.92)
    [gui]The commander minimap is rather oddly offset to the cursor on this side of the map<!--QuoteEnd--></div><!--QuoteEEnd-->
  • LazerLazer Join Date: 2003-03-11 Member: 14406Members, Contributor, Constellation, NS2 Playtester
    edited May 2011
    <!--quoteo(post=1844153:date=May 4 2011, 09:08 PM:name=Kouji_San)--><div class='quotetop'>QUOTE (Kouji_San @ May 4 2011, 09:08 PM) <a href="index.php?act=findpost&pid=1844153"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->@Lazer: The minimap offset is wrong for rockdown currently (might have something to do with is being weirdly positioned ingame for the commander mode as well<!--QuoteEnd--></div><!--QuoteEEnd-->
    Yes but I believe this is just in-game. It's an issue that has come up recently but because I'm writing my own map extends for each map overview on the site I don't think the in-game glitch is reflected there, and if so it can be easily adjusted. The best way for me to 'calibrate' would be if an annotation was left in the center of a few distant rooms with the room names it could be easily aligned/scaled more accurately until a better solution comes up.
Sign In or Register to comment.