Script debugging

This was my first run to get script debugging working
so maybe there's an easier way.

  • start REDKit and load a world (for me it was L02-port.w2w)
  • bevor hitting the button "Play Game" I had to press "Load a saved game"
..........(because left Ctrl for meditating menu didn't work)
  • start the Script Studio ("The Witcher 2\bin\scriptStudio.Release.exe")
  • edit guifastmenu.ws (game\gui);
..........insert tostartpoint() ; as new line 51 after line 50
..........save changed script; maybe F7 required to reload scripts
  • toggle breakpoint by clicking LMB just BEHIND the line number 51
..........(a hollow circle should appear)
  • click "Connect to running game" button
..........(Breakpoint circle should change to a filled red one now)
  • move to REDkit and press left Ctrl
..........game should freeze
  • move to script studio
..........Breakpoint should be hit
  • hit F11 (step into) and mati_test.ws should pop up
  • perform the script lines of script function tostartpoint() by F10
..........have a look at Pos in locals tab; it's 0,0,0,0
  • after execution of thePlayer.Teleport( pos ); press F5
  • move to game again; press meditation button and ESC
(no, player did not move, maybe 0,0,0,0 is not located in the current level)

It's useful to create a copy named tostartpoint1() in guifastmenu.ws
(place it before class CGuiFastMenu extends CGuiPanel for example)
Try to use another tag than 'start' for your teleportation aim.

Nevertheless, HTH
shak-otay