
fifaFS
Script files command set
========================


VARIABLES
---------

set $var1$ , string {any string}
sets value "any string" to $var1$

set $var2$ , registry {HKEY_LOCAL_MACHINE : Path : Key name}
sets value from registry contained in specified path and key name

write registry {HKEY_LOCAL_MACHINE : Path : Key name}, string{any string}
writes value to registry

set $var3$ , exists{filename}
sets "true" to $var3$ if filename exists and "false" if not

Note:
There are predefined values, containing games' installation folders:
 - $dir_fifawc06$
 - $dir_wc06demo$
 - $dir_fifa06$
 - $dir_fm06$
 - $dir_fifa2005$
 - $dir_uefa2005$
 - $dir_tcm2005$

And also variable:
 - $mydocumentsfolder$, 
containing path to User's My Documents folder.

Run "fifafs.exe -info" to get full list of variables.


WORKING WITH FIFA FILE SYSTEM
-----------------------------

By default, fifaFS is set to deal with FIFA 06 file system.
It all about fifa.fat regeneration features.

Please note if you are going to deal with another games,
use 'gametype command' with the following arguments:

gametype uefa07
gametype fm07
gametype fifa07
gametype fifa07demo
gametype fifa06
gametype fifawc06
gametype wc06demo
gametype fm06 
gametype fifa2005
gametype uefa2005


File system commands:

mountfs path_to_fifa2005\data
Defines fifa file system location

-r   intname    , extname  -  replace intname with extname
-r   intname |c , extname  -  replace intname with compressed extname

-a   intname    , extname  -  add extname as "intname"
-a   intname |c , extname  -  add compressed extname as "intname"

-a|5 intname    , extname  -  add extname as "intname" into zdata_05.big
-a|5 intname |c , extname  -  add compressed extname as "intname" into zdata_05.big

-ar  intname    , extname    -  replace or add
-ar  intname |c , extname    -  guess what

-ar|5  intname    , extname  -  replace or add into zdata_05.big
-ar|5  intname |c , extname  -  guess what into zdata_05.big

-e   intname , extname       -  export intname into extname

-del intname                 -  delete file with specified intname

Note:
You can use placeholders in filenames for example instead of:
-r playertexobj.texobj11__texture14__0_139716_0.fsh |c, playertexobj.texobj11__texture14__0_139716_0.fsh

You may write mask:
-r *|c, pla*.fsh

Please note, that you can't specify 
internal name if you use file mask - that is why only "*|c" written, 
internal name is automatically set to external in that case.

You may use placeholders in exporting too:
-e pla*.o, faces\*.*

Again, you can't specify external name in that case, 
but you can specify folder.




FSH Hashing
-----------

Read more about it in fshhashing.txt
Possible values:
fshhashing off                  
fshhashing random_only          
fshhashing retrieve_only
fshhashing retrieve_and_random 





IF Clause
---------

if (condition)
 ...
endif

As (condition)
you may write:

if $var1$ == string{123} 
 ...
endif

or 

if $dir_fifa2005$ != string{}
 ...
endif

or even

if exists{$dir_fifa2005\data\gui\main.big} == true
 ...
endif


Also you can use labels:
goto @label1
...
@label1

If's, label's and goto's allowing to create complicated scripts.
For example you can make patch installation dependable 
on previous patch version.

Example:

set $ver$, registry{HKEY_LOCAL_MACHINE: software\my company\my patch: version}

if $ver$ == string{1.1}
 ...
 goto @end
endif

if $ver$ == string {1.2}
 ...
 goto @end
endif

if $ver$ == string {1.3}
 trace Patch already installed
 break
endif

@end
...
write registry{HKEY_LOCAL_MACHINE: software\my company\my patch: version}, string{1.3}






WORKING WITH BIG'S
------------------

mountbig path_to_big, bigid  -  mount big-file with special bigid, 
                                which you must specify later in commands

createbig path_to_big, bigid -  create and mount new big file


-r  intname    , extname, bigid  -  see description above... 
                                    "bigid" means that command is applyed to
                                    big file mounted with ID "bigid"

-r  intname |c , extname, bigid

-a  intname    , extname, bigid
-a  intname |c , extname, bigid

-ar  intname    , extname, bigid
-ar  intname |c , extname, bigid

-e   intname, extname, bigid

-del intname, bigid

You also may use placeholders in filenames here.



MISC
----

disablebh  - no .BH files will be generated
include scriptfile - includes specified file (other script) to script :)
break message - stops script execution and writes message to log
trace message - writes message to log


ATTENTION! Commands changed.
----------------------------
Instead of old "-mkdir" and "-rmdir" use just "mkdir" and "rmdir"
mkdir dirname            - create "dirname" folder
rmdir dirname            - delete "dirname" folder


Attention! This commands are not active since v.4.6
------------------------------------------------
saves_move_to fifa2005, dirname        - moves (not copying) saves to folder "dirname"
saves_restore_from fifa2005, dirname   - restores saves from folder "dirname"
saves_remove fifa2005                  - just kills saves
Here, instead of fifa2005, you can specify:
uefa2005, tcm2005


WARNING! 
========
-cp command is deprecated. Now, instead of "-cp destination, source"
use "copy source, destination" 
"source" and "destination" are filenames or directories
(placeholders may be used)




====================================================
Maybe you want us to add another dozen of commands?
For example, "copy" was added after one patchmaker
asked for it. The same story was for "-del", "fixfs"
and "createbig" commands.

Please suggest here:
www.fifasoccer.ru/en/forum
admin@fifasoccer.ru
thegood@fifasoccer.ru
===================================================


(c) Mania Software, 2001-2009
www.fifasoccer.ru/en

