FSM – Talk

From Bohemia Interactive Community
Jump to navigation Jump to search
Line 52: Line 52:
I find the description in the article very unclear. The information as it is now is pretty useless for me because I can't connect it to anything. I have been working with the .fsm files from the characters.pbo so far. I assume those are the scripted types. Where do I find the "native" types? -- [[User:Donnervogel|Donnervogel]] 03:33, 5 March 2007 (CET)
I find the description in the article very unclear. The information as it is now is pretty useless for me because I can't connect it to anything. I have been working with the .fsm files from the characters.pbo so far. I assume those are the scripted types. Where do I find the "native" types? -- [[User:Donnervogel|Donnervogel]] 03:33, 5 March 2007 (CET)
: afaik you can find them in configs. For example I remember a FSM for the dragonflies in the config. --[[User:T D|T_D]] 11:34, 5 March 2007 (CET)
: afaik you can find them in configs. For example I remember a FSM for the dragonflies in the config. --[[User:T D|T_D]] 11:34, 5 March 2007 (CET)
:: ah ok thank you. Well I saw them before but I though they were somehow a part of the .fsm files because most states and links are identically named. But now I had a look at the animal FSM class and I don't find any .fsm files for them. SO it looks that they are different things. Plus there are some differences in the FSM class for units and the .fsm Files. --[[User:Donnervogel|Donnervogel]] 12:01, 5 March 2007 (CET)

Revision as of 13:01, 5 March 2007

OK, I know this is highly preliminary and full of assumption but I am hoping to spur some more testing or release of hard facts from BIS regarding this file structure. Heck, I am going off second hand info to get this. --CrashDome 08:06, 4 December 2006 (CET)

Hello Crashdome. From here : http://kronzky.info/misc/animals-config.zip , it looks like, at least in .cpp, the condition/actions may not be a simple script, but takes argument :

  class MoveCompleted {
   priority = 1.000000;
   to = "SetRandom3";
   class Condition {
     function = "moveCompleted";
     parameters = {};
     threshold = 0;
   };
   class Action {
     function = "nothing";
     parameters = {};
     thresholds = {};
   };
  };

probably referencing a function defined somwhere else in the cpp. - Whisper 18:30, 6 December 2006 (CET)

Thanks Kronzky, but I think those are config specific and useful for addons. However, all mission examples are different and more simplistic, BUT it is still important. I wish I had a copy of ArmA to do tests. When I get one, I will elaborate - if not already done so by someone else. --CrashDome 23:41, 6 December 2006 (CET)

A first detailed view of the soldier FSM, very simplified, by SoldierIsNotHistory : http://soldierisnothistory.free.fr/OperationFlashpoint/AI_soldier.png (from arma-fr.net forums) - Whisper 16:57, 7 December 2006 (CET)


Nice work there on that chart! Pretty impressive job decoding it, and pretty interesting what kind of things this might enable scripters to do.

For now though, I have decided not to waste anymore time into "reverse-engineering" FSM...
BIS has a different attitude towards the community than they did when they released OFP. They know now that the addon and mission-makers are one of their strongest assets (that's why the Wiki), so unlike back then, where one *had* to figure stuff out yourself if you wanted to get into modding/scripting, I am sure this time around we will get some sort of documentation pretty soon.
So I could either spend the next few weeks trying to decypher FSM, only to have it then verified by the released documentation, or I could spend that time enjoying ArmA, familiarizing myself with the new concepts that are already documented, and then fully dive into FSM once the documentation is out.
(But I also know the thrill to trying to figure something out by yourself - without any outside help or documentation, so I do understand if other people chose not to wait...) --Kronzky 17:20, 7 December 2006 (CET)

The thing I'm afraid, is that more than documentation will be required. It looks really uneasy to built FSM files with a simple text editor, a bit like it's not easy to create a functionnal mission.sqm with only notepad ;) I think we'll need a tool to edit/create FSMs. And BIS doesn't look like they're gonna release FSMEditor tool, so someone will probably have to do it (like the first released mission editor for OFP demo where created by players) -- Whisper 17:39, 7 December 2006 (CET)


I hopefully will have good news for both of you. Kronsky, yes I have same feeling that BIS will release more information when the time is right. Whisper, I've already half created a graphical FSM editor. Great work on the graph btw. Here's to hoping that all goes as we expect - cheers! --CrashDome 07:50, 8 December 2006 (CET)

finalState

finalStates: This property takes an array of string arguments. Current purpose unkown.

A final state stops the execution of a FSM. Let's say you have a FSM which orders a soldier to move from point A to point B. You can have 2 states then:

STATE 1: Move to B.
STATE 2: B reached.

State 2 should be a final state then and exit the FSM, as there is nothing left to do.

Difference Between Scripted and Native Type?

I find the description in the article very unclear. The information as it is now is pretty useless for me because I can't connect it to anything. I have been working with the .fsm files from the characters.pbo so far. I assume those are the scripted types. Where do I find the "native" types? -- Donnervogel 03:33, 5 March 2007 (CET)

afaik you can find them in configs. For example I remember a FSM for the dragonflies in the config. --T_D 11:34, 5 March 2007 (CET)
ah ok thank you. Well I saw them before but I though they were somehow a part of the .fsm files because most states and links are identically named. But now I had a look at the animal FSM class and I don't find any .fsm files for them. SO it looks that they are different things. Plus there are some differences in the FSM class for units and the .fsm Files. --Donnervogel 12:01, 5 March 2007 (CET)