Accueil Crush your enemies... and create an EMPIRE!!! Space Empires V -- BUY NOW!!!

Connexion utilisateur

  • Créer un nouveau compte
  • Demander un nouveau mot de passe

Navigation

  • news
    • archive
    • blogs
    • books
    • forums
    • recent posts
    • groups
  • image galleries
  • projects & downloads
  • search
  • create content
  • agrégateur de nouvelles

Rechercher

Qui est en ligne

Il y a actuellement 1 utilisateur et 147 invités en ligne.

Utilisateurs en ligne

  • bauscho

Languages

  • English English
  • French French

Parcourir les archives

« December 2008  
Mo Tu We Th Fr Sa Su
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        
Accueil » news » forums » Support & Feedback » Scenarios & Mods » SE:V MODs

Is there a script debugger??

Soumis par pkoko le Mer, 2007-10-31 16:33 SE:V MODs

To those mod makers especially AI upgrade mods; Is there a script debugger that work with SE's script parser or compiler??

Another way to rephrase the question:
How do AI moders know that the computer executes their AI commands properly. How do they know the return value of a specific function in SE5?

‹ A new way to texture your shipsets! International speech files? ›
» Vous devez vous identifier ou créer un compte pour écrire des commentaires

Options d'affichage des commentaires

Sélectionnez la méthode d'affichage des commentaires que vous préférez, puis cliquez sur "Sauvegarder les paramètres" pour activer vos changements.
Mod Designer

Re: Is there a script debugger??

Soumis par Gideon le Mer, 2007-10-31 16:36

The compiler checks for errors automatically.

Aside from that, the only tools I know of for detecting what you are asking is through observing the AI in action.

"Only by being constantly at war with evil in all things, including yourself, can you truely know peace."
Download my mod here: GidMod
or there:

» Vous devez vous identifier ou créer un compte pour écrire des commentaires
Image de RogerN

Re: Is there a script debugger??

Soumis par RogerN le Mer, 2007-10-31 16:40

I think you can turn on logging and then add some output statements to your scripts. I've never tried it, however.

» Vous devez vous identifier ou créer un compte pour écrire des commentaires
Image de Isopsyco
Mod Designer

Re: Is there a script debugger??

Soumis par Isopsyco le Mer, 2007-10-31 17:45

You can script in some commands to log events (variables, and such) to check where or when something should execute (or if it didn't). A memory dump of all the variables by name is what I use, it lest me know if they were initialized or not, if they got the right number at the right turn.

But other than that, you have to know your scripting code is set up logically. The parser will compile bad code (syntax aside), say, loop forever mess up will hang your game.

» Vous devez vous identifier ou créer un compte pour écrire des commentaires
Image de Captain Kwok
Mod Designer

Re: Is there a script debugger??

Soumis par Captain Kwok le Mer, 2007-10-31 18:11

The file DebugSettings.txt in the data folder allows you to debug various things, including the execution of the various scripts.

Only the changing the DebugSettings.txt file in the default data folder will cause debug logs to be printed. To have logs made of the script execution, you'll want to set "Debug Section Script Evaluation Detailed := TRUE". This will create a big text file in the backup folder under the player name and turn number. It's a line by line print out of that AI's script being executed... these files get big fast as the number of game objects increase. The "simple" version is about half as much detail.

Below are the typical settings I use for debugging. If you look at my source AI scripts, you'll see I use the script function "Sys_Debug_Print" a lot to print out specific things about the AI in conjunction with setting "Debug Print Sections := TRUE". This produces a condensed log of only items I want to know each turn.

Generate Game Debug Log                                 := TRUE
Generate Engine Debug Log                               := FALSE
Use Fast Debug Log                                      := FALSE
Debug Section Engine Startup                            := FALSE
Debug Section Creation                                  := FALSE
Debug Section Sound Base                                := FALSE
Debug Section Display Class                             := FALSE
Debug Section Sobj Ship                                 := FALSE
Debug Section Display Object                            := FALSE
Debug Section Formula Evaluation                        := FALSE
Debug Section Script Evaluation Detailed                := FALSE
Debug Section Script Evaluation Simple                  := FALSE
Debug Section Script Evaluation Debug Print Only        := TRUE
Debug Print Sections                                    := Colonies, Construction, Intel, Planets, Politics, Research, Ships, State, System
Debug Section Compute Highest Tech Level                := FALSE
Debug Section Master State Machine                      := FALSE
Debug Section Order Execution                           := FALSE
Debug Section Combat                                    := FALSE
Debug Section Combat Speed                              := FALSE
Debug Section Main Drawing Loop                         := FALSE
Debug Section TCPIP                                     := FALSE
Debug Section End All Players Turn                      := FALSE
Debug Section Host Processing                           := FALSE
Debug Section Phased Movement                           := FALSE


Space Empires Depot | SE:V Balance Mod

» Vous devez vous identifier ou créer un compte pour écrire des commentaires
Mod Designer

Re: Is there a script debugger??

Soumis par pkoko le Mer, 2007-10-31 18:39

thanks everyone. Special thanks to Captain Kwok; this what I needed to debug some AI information. I can't promise I will do anything; I was curious on how the AI in SE5 thought and executed commands.

Anyway, I think the above information needs to a be sticky or posted on wiki for those who want to create AI mods or any game mechanics changes like intelligence, ect.

So maybe when school is over for Christmas; I will have some time to fool around with it. I can't promise anything though. As I said, I never did AI work before.

» Vous devez vous identifier ou créer un compte pour écrire des commentaires
Mod Designer

Re: Is there a script debugger??

Soumis par Gideon le Mer, 2007-10-31 18:52

Nice, thanks Kwok.

"Only by being constantly at war with evil in all things, including yourself, can you truely know peace."
Download my mod here: GidMod
or there:

» Vous devez vous identifier ou créer un compte pour écrire des commentaires

Options d'affichage des commentaires

Sélectionnez la méthode d'affichage des commentaires que vous préférez, puis cliquez sur "Sauvegarder les paramètres" pour activer vos changements.

Now on STEAM

Now on STEAM!Space Empires V via STEAMSpace Empires IV via STEAMSTEAM online by Valve Corporation

Contenu populaire

Aujourd'hui :

  • Research By Percentage SUCKS
  • Is the Patch Process Dead, and Other Thoughts...
  • Known SE5 v1.74 Bugs
  • Babylon 5 Wars SEV Mod Update
  • Space Empires V 1.74

Depuis toujours :

  • Space Empires V and VI: Expansions and the Future: Tell the Company What's on Your Wish List
  • Space Empires V
  • Gritty Galaxy Fleet Clash
  • Damn Dirty Bugs/Annoyances
  • Space Empires V: General Thoughts, Observations, and Suggestions

Dernier accès :

  • Domed colonies in the AI script (or "Is there air?!? You don't know!")
  • Nichtangriffspakt / Nonaggression treaty
  • Odd quadrant generation problem in 1.74 when tweaked for over 100 systems.
  • Patches
  • New pic's for space V
(c) Strategy First, Inc. All rights reserved.