Yankee

  • Newbie
  • Posts: 48
[ #D~ Tools ] Re: Map Editor
« Reply #120,  »
I can't use /exportmap command,it isn't work.If i type this command,nothing happens.Please help me.

kennedyarz

  • Sr. Member
  • Making American Great Again
  • Posts: 334
[ #D~ Tools ] Re: Map Editor
« Reply #121,  »
Quote from Yankee on August 8th, 2017, 02:14 PM
I can't use /exportmap command,it isn't work.If i type this command,nothing happens.Please help me.
Make a new topic, but take note of this, place the IMPACT font underline it and then change its layout to the maximum. So that people can see more, even a blind man. You already know how to do it

Yankee

  • Newbie
  • Posts: 48
[ #D~ Tools ] Re: Map Editor
« Reply #122,  »
Quote from kennedyarz on August 9th, 2017, 04:21 PM
Quote from Yankee on August 8th, 2017, 02:14 PM
I can't use /exportmap command,it isn't work.If i type this command,nothing happens.Please help me.
Make a new topic, but take note of this, place the IMPACT font underline it and then change its layout to the maximum. So that people can see more, even a blind man. You already know how to do it
We used same size layout.What is your problem ?Did I do something wrong ?

Doom_Kill3R

  • VC:MP Beta Tester
  • Infinite loops defy infinity by overflowing memory
  • Posts: 1,082
[ #D~ Tools ] Re: Map Editor
« Reply #123,  »
Make sure you have your map opened and there is something actually mapped. Afterwards make sure that when you type the exportmap command you wait for a success message. Then you can take the resulted outputs from the Maps/MapName folder.

Yankee

  • Newbie
  • Posts: 48
[ #D~ Tools ] Re: Map Editor
« Reply #124,  »
Quote from Doom_Kill3R on August 10th, 2017, 11:05 AM
Make sure you have your map opened and there is something actually mapped. Afterwards make sure that when you type the exportmap command you wait for a success message. Then you can take the resulted outputs from the Maps/MapName folder.
Problem is solved,thanks.

Xmair

  • Wiki Contributor
  • Posts: 857
[ #D~ Tools ] Re: Map Editor
« Reply #125,  »
@Doom_Kill3R
In the "allmaps" and "alllocs" command, the first map/loc won't be listed. To fix this, use:
Code: [Select]
else if( cmd == "allmaps" || cmd == "maps" || cmd == "getmaps" )
{
local listQuery = QuerySQL( Maps, "SELECT * FROM sqlite_master WHERE type='table'" );
local count = 0;
while ( GetSQLColumnData( listQuery, 0 ) ) {
count++;
MessagePlayer( "[#00CC00][MAP#" + count + "]: [#FFFFFF]" + GetSQLColumnData( listQuery, 1 ), player );
GetSQLNextRow( listQuery );
}
if( count == 0 ) return MessagePlayer( "[#00CC00][ERROR]: [#FFFFFF]No maps to list!", player );
}

else if( cmd == "alllocs" || cmd == "locs" || cmd == "getlocs" )
{
local listQuery = QuerySQL( db, "SELECT * FROM `Gotoloc`" );
local count = 0;
while ( GetSQLColumnData( listQuery, 0 ) ) {
count++;
MessagePlayer( "[#00CC00][LOC#" + count + "]: [#FFFFFF]" + GetSQLColumnData( listQuery, 0 ), player );
GetSQLNextRow( listQuery );
}
FreeSQLQuery( listQuery );
if( count == 0 ) return MessagePlayer( "[#00CC00][ERROR]: [#FFFFFF]No locations to list!", player );
}
The problem was caused because you were using
Code: [Select]
while ( GetSQLNextRow( listQuery ) )
which would go to the next row without printing the first one.
I convert minecraft worlds to VCMP, if you want your worlds to be converted, shoot me a PM! (Please note the paintings, flower pots, armour stands and custom skulls won't be converted within the model. Also big objects won't be converted)

Doom_Kill3R

  • VC:MP Beta Tester
  • Infinite loops defy infinity by overflowing memory
  • Posts: 1,082
[ #D~ Tools ] Re: Map Editor
« Reply #126,  »
No need to do such a big change, it can be simply fixed with a do statement.

Code: [Select]
else if( cmd == "alllocs" || cmd == "locs" || cmd == "getlocs" )
{
    local listQuery = QuerySQL( db, "SELECT * FROM `Gotoloc`" );
    local count = 0;
    do {
        count++;
        MessagePlayer( "[#00CC00][LOC#" + count + "]: [#FFFFFF]" + GetSQLColumnData( listQuery, 0 ), player );
    }
    while ( GetSQLNextRow( listQuery ) )
    FreeSQLQuery( listQuery );
    if( count == 0 ) return MessagePlayer( "[#00CC00][ERROR]: [#FFFFFF]No locations to list!", player );
}

=RK=MarineForce

  • Sr. Member
  • why noise ??? Re 100%
  • Posts: 389
[ #D~ Tools ] Re: Map Editor
« Reply #127,  »
@Doom_Killer There is a bug, when i added object and trying to select it it shows Invaild id, its true ID of that,

[#00CC00][MAP]: [#ffffff]Created object 535
[#00CC00][ERROR]: [#FFFFFF]Invalid object ID!