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 2 utilisateurs et 108 invités en ligne.

Utilisateurs en ligne

  • Randallw
  • GambitUK

Languages

  • English English
  • French French

Parcourir les archives

« September 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          
Accueil » news » forums » Support & Feedback » Scenarios & Mods » SE:V MODs

Working Example of the Sys_Get_AI_Storage_Long and Sys_Set_AI_Storage_Long functions

Soumis par unnamed le Mer, 2007-06-20 20:24 SE:V MODs

I'm looking for a working example of the Sys_Set_AI_Storage_Long and Sys_Get_AI_Storage_Long functions. All I want to do is save a single long value from one turn and retrieve it the next. Apparently what I'm doing is wrong, and my brain hurts from memorizing law bull****, so I dont have the patience to work it out myself right now. THanks

-unnamed

‹ Balance Mod v1.07 Available! Star Wars Universe Mod ›
» 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.

Re: Working Example of the Sys_Get_AI_Storage_Long and Sys_Set_A

Soumis par homo ludens le Jeu, 2007-06-21 02:54

As i remember, to save values from one turn to another there are special functions which described in scripting manual. Don't remember its names. It is in the section concerns AI. Theese functions save lists of values and you can access to certain value by giving the list number and listindex in the specified list as params to the function. Just like a two-dimensional array.

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

Re: Working Example of the Sys_Get_AI_Storage_Long and Sys_Set_A

Soumis par Thy Reaper le Ven, 2007-06-22 15:34

What you've just described is exactly what he mentioned.

Stock's diplomacy makes use of these functions I believe. The syntax should be function(player_id, list_num, element_num).

So you'd call Set([player_id], 2, 1), then Get([player_id], 2, 1) on the subsequent turn. What's the code you're currently using?

-----
Space for rent - please contact owner

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

Re: Working Example of the Sys_Get_AI_Storage_Long and Sys_Set_A

Soumis par unnamed le Mar, 2007-06-26 18:51

Thanks for the input homo ludens and Thy Reaper.

I was doing it correctly but another function used the same save location (politics or statechange) and was zeroing out my saved number. Also, I forgot to put a default number in at an appropriate point and it game me garbage because of it. All good now though. Thanks

-Scott

» 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 :

  • Ship Capture Issues
  • Space Empires V
  • Hows the current AI?
  • Space Empires V and VI: Expansions and the Future: Tell the Company What's on Your Wish List
  • SE5 Multimedia Pack

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 :

  • Supply usage bug (in my mod).
  • some stuff I use without support for AI - Crew
  • Crystalline Armor?
  • Help for Patch installation
  • Weapon Platforms and Ground Combat
(c) Strategy First, Inc. All rights reserved.