Author Topic: Scripting intergration with SGDK  (Read 3491 times)

jweldon

  • Visitor
  • *
  • Posts: 16
    • View Profile
    • Email
Scripting intergration with SGDK
« on: 2005-12-28, 11:29:06 PM »
I am confussed on how to edit my game (add scripting to it)  How do I look at the script for my game in my Visual basic 6.0 program?  I just recently bought a VB Studio 6.0 so I can learn scripting for games.  It's not the enterprize version but I think it will do for me.  Do I save my game as a .exe file and then open it in my VB 6 program?  When I mess with the scripting wizard I see how you can view the script there, but is that all of the script for the whole game or is that just the fire weapon, radar, and jump script section that I load in the player settings part?

Thanks for any advice,
John

PS how is SGDK 2.0 coming along?  Can you share what might be some of the new features of it?

bluemonkmn

  • SGDK Author
  • Administrator
  • Fanatic
  • *****
  • Posts: 2761
    • ICQ Messenger - 2678251
    • MSN Messenger - BlueMonkMN@gmail.com
    • View Profile
    • http://sgdk2.sf.net/
    • Email
Re: Scripting intergration with SGDK
« Reply #1 on: 2005-12-29, 09:47:20 AM »
1. If you want to use VBScript to customize a game (the kind of script that the scripting wizard creates) you just edit it in Notepad or use the scripting wizard to create it.  It should be saved as a .VBS file (make sure it is not a TXT file if you are using notepad).  Visual Studio / Visual Basic are not required (and can't really be used at all) for scripting really.

2. It is possible to use Visual Basic 6.0 to customize the game by creating a compiled COM component that connects to GameDev, but that is a more advanced topic.

3. The scripting wizard cannot edit/view scripts that have already been created.  It is designed for creating new scripts.  Editing scripts should be done with a text editor like Notepad.

4. The scripting wizard only creates script for performing specific actions.  The script it creates does not contain code for controlling the whole game.

5. You can download the SGDK2 pre-alpha demo to see exactly how it is so far -- check the announcements forum for information about how.

cbass

  • Expert
  • Regular
  • *****
  • Posts: 97
  • script this
    • View Profile
    • Squest RPG
Re: Scripting intergration with SGDK
« Reply #2 on: 2005-12-29, 04:43:16 PM »
if you have visual basic, and are interested in using a compiled COM component instead of script, here is a quick demo I put together a while back.  It gives you a working project to start from if you have no idea where to start.  Just load the SGDKCOMprojectgroup.vbg file in visual basic and hit f5 to play the project.

If you just want to start using regular script, there are dozens of examples to look at on how to start.  Just start from a premade script, or if you want to learn from scratch, the easiest way is to just start a new project and cut and paste a script in a new .vbs file in notepad, attach the script, and try to get the project to start with the script attached.  Once you do, try to add to the script, or add an error to the script (i=0/0) to make sure  its attached and the code is running.

Come here with any questions.