Show
Ignore:
Timestamp:
04/13/10 17:06:34 (2 years ago)
Author:
Carsten
Message:

a) Changed the format of pts pointfiles to Lua. That is, pointfiles are now true, complete Lua programs:

  • CaBSP has been updated to write pointfiles in the new format as Lua programs,
  • CaWE has been updated to run pointfiles as Lua programs and to look into the generated Points table for the results.

b) Added a new recordPath() console function to the Cafu game client that allows recording the path of the player.

(This functionality has been asked for by Dennis Köhler from the FH Dortmund for running a new set of scientific tests.)
The recored paths are saved in the same pointfile format as those for leaks, and thus can uniformly be loaded into CaWE for visualization!

c) CaWE: Fixed occurrences of wxMessageBox(..., wxOK | wxICON_...) being called without the wxOK constant.

Some open issues for future consideration:
- Allow record-style initialization besides the existing list-style initialization.
- Support setting a custom line color in the pointfile.
- In CaWE, visualize not only the point coordinates, but also the time, heading, comments, ...

Example future pointfile:

Points=
{

-- color="blue", -- Any string that the wxColour() ctor recognizes.

-- Use record-style or list-style initialization.
{ 0; -1695, -498.692, -67.9358; 9874; "" },
{ 5.26625; -1697.05, -482.187, -67.9358; 64250; "" },
{ 5.77412; -1711.62, -364.583, -67.9358; 64250; "" },
{ t=6.30243; x=-1726.45, y=-243.117, z=-67.9358; hdg=64310; comment="" },
{ t=6.80414; -1740.28, -125.456, -43.9358; hdg=64640; "" }, -- mixed...

}

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • cafu/trunk/CaWE/GuiEditor/ChildFrame.cpp

    r36 r48  
    362362        wxMessageBox(wxString("I was not able to backup file '")+FileName+"' to '"+FileName+"_bak"+"'.\n" 
    363363                     "Please make sure that there is enough disk space left and that the path still exists,\n" 
    364                      "or use 'File -> Save As...' to save the current GUI elsewhere.", "File not saved!", wxICON_ERROR); 
     364                     "or use 'File -> Save As...' to save the current GUI elsewhere.", "File not saved!", wxOK | wxICON_ERROR); 
    365365        return false; 
    366366    } 
     
    667667                                 "This is most likely a problem in your custom script code that you should look into.\n"+ 
    668668                                 "We will proceed anyway, using the script portions that were loaded before the error occurred.", 
    669                                  MainScriptFileName, wxICON_EXCLAMATION); 
     669                                 MainScriptFileName, wxOK | wxICON_EXCLAMATION); 
    670670                } 
    671671 
     
    676676            { 
    677677                // Getting here means the GUI has no root window set, but this should never happen within CaWE. 
    678                 wxMessageBox("There was an error initializing the live preview from script\n"+MainScriptFileName, "Live Preview", wxICON_ERROR); 
     678                wxMessageBox("There was an error initializing the live preview from script\n"+MainScriptFileName, "Live Preview", wxOK | wxICON_ERROR); 
    679679            } 
    680680