Professional Documents
Culture Documents
3
---------------------------------------------------------------
1 What you get
1.1 Legal stuff
1.2 Included files
1.2.1 My codecreator
1.2.2 My GTA VC GXT editor
1.2.3 Source codes
1.2.4 Stripped mission scripts
1.2.5 List of opcodes
1.3 Version info
2 Installation
2.1 Starting the mission builder
3 The IDE
3.1 Buttons and menues
3.1.1 The F1 key
3.2 Working with files
4 Mission coding
4.1 Definitions used in this readme
4.2 The mission script
4.2.1 The segments
4.2.2 The MAIN part of the mission script
4.2.3 The MISSION part of the mission script
4.3 Data types
4.3.1 Floating-point numbers
4.4 Local variables
4.5 Global variables
4.6 Equates
4.7 Arrays
4.8 Mathematical coding
4.8.1 Setting variables
4.8.2 Addition
4.8.3 Subtraction
4.8.4 Division
4.8.5 Multiplication
4.9 Conditional coding
4.10 Conditional math coding
4.10.1 Checking the value of variables
4.10.2 Using the NOT operator
4.11 Setting the data type of operations
4.12 Jump instructions
4.12.1 Using variables in jump instructions
4.13 Writing a mission script from scratch
4.14 Writing a mission from scratch
4.15 Rules that must be followed when coding
4.15.1 wait codes
4.15.2 create_thread commands
4.15.3 Requesting models
4.16 Practical Issues
5 Mission coding for newbies and retards :p
6 Support
7 Changes
------------------
1 What you get
1.1 Legal stuff
I take no responsibility for any persons use of the
mission builder in any way. Use it at your own risk.
Since this mission builder is based on others work and
since those other people made some rules about what their
work could be used for, I included some information about
that in the STUFF folder. You should read through these
files since some of them have some useful information
about using the IDE.
---------------------------------------------------------------
2 Installation
Unzip to anywhere. Run 'ViceBuilder13.exe'. The first time
you run the program, you must specify where you installed Gta Vice.
NOTE! If you get an arrow with that hour-glass, you can still
use the arrow to set up the mission builder.
and press the F1 key, every time you press F1, you get another
match. When you press F1 on lines that doesn't have any
underscores at all, the result doesn't include any either.
With "thread", you get one of these:
00D7: create thread with wasted busted check ££Label011C74
004F: create thread ££Label0091D0
004E: end thread
03A4: name thread "MAIN"
Another example, you want to know what opcodes are used with
"create_actor". Every time you press F1, the line toggles
between these commands:
0129: $912 = create_actor 8 #HNB in_car $94C driverseat
01C8: $8F5 = create_actor 10 #CLB in_car $8F8 passenger_seat 0
009A: $2D3 = create_actor 4 #PGA at 10@ 11@ 12@
This version also allows you to search for keywords and logic
synonyms to keywords. Some of these keywords match keywords
used in GTAMA. Some keywords have up to 5 synonyms.
The list is in the 'keywords.txt' file. The MB reads this
list, so if you want more synonyms, you can add them to this
file.
If you want to add keywords to this file, you must follow
these rules:
- Use letters and numbers only.
- Spaces and underscores are not allowed inside keywords.
- After the keyword, add a single space.
- After the space, add the opcode that the synonym is to
be linked with. The opcode must be in hexadecimal format
and always 4 letters (or numbers) long.
------------------------
4 Mission coding
4.1 Definitions used in this readme
In this readme, a mission script is either a compiled '.scm'
file or a text file containing script source code.
A segment is a chunk of compiled code. The term "script code"
or "code line" is any line of text looking like this:
03CB: set_camera 807.0 -937.0 36.5625
| | |
| | |
| | |
| | |_____ *3
| |
| |___________________________ *2
|
|______________________________________ *1
*1 This is an opcodes.
*2 This is the command string. This part is ignored by this
version of this mission builder (and any future versions).
*3 This is a number.
4.6 Equates
Equates are variables set up internally in the mission builder. When
the mission builder is loading, it reads the 'default.ide' file and
stores all the definitions it finds in that file into equates. This
means that if you want to create a car and you need the number of
the model name of that car, you just use the equate of that car
instead. Like: $CarModelNumber = #cheetah
4.7 Arrays
Use DEFINE ARRAY $<global variable> <size> <INTEGER|FLOAT>
to set up an array.
Use
$<global variable>_index = <index>
to set the index of the array.
Use SET_ARRAY $<global variable>
to set $<global variable><index> to $<global variable>
Use GET_ARRAY $<global variable>
to set $<global variable> to $<global variable><index>
For more information about arrays, look into
'Mission Mods\CrazyBikeTraffic.txt'
4.8.2 Addition
To add an integer number to a global variable, use
$<global variable name> += <integer number>
To add a floating-point number to a global variable, use
$<global variable name> += <floating-point number>
To add a global variable containing an integer value to
another global variable also containing an integer value, use
INT $<global variable name> += $<global variable name>
To add a global variable containing a floating-point value to
another global variable also containing a floating-point value, use
FLOAT $<global variable name> += $<global variable name>
Use the same method with local variables and any combinations
of global and local variables. See '4.3.1 Floating-point numbers'
for more information about floating-point numbers and integer numbers.
4.8.3 Subtraction
To subtract an integer number from a global variable, use
$<global variable name> -= <integer number>
To subtract a floating-point number from a global variable, use
$<global variable name> -= <floating-point number>
To subtract a global variable containing an integer value from
another global variable also containing an integer value, use
INT $<global variable name> -= $<global variable name>
To subtract a global variable containing a floating-point value from
another global variable also containing a floating-point value, use
FLOAT $<global variable name> -= $<global variable name>
Use the same method with local variables and any combinations
of global and local variables. See '4.3.1 Floating-point numbers'
for more information about floating-point numbers and integer numbers.
4.8.4 Division
To divide a global variable with an integer number, use
$<global variable name> /= <integer number>
To divide a global variable with a floating-point number, use
$<global variable name> /= <floating-point number>
To divide a global variable containing an integer value with
another global variable also containing an integer value, use
INT $<global variable name> /= $<global variable name>
To divide a global variable containing a floating-point value with
another global variable also containing a floating-point value, use
FLOAT $<global variable name> /= $<global variable name>
Use the same method with local variables and any combinations
of global and local variables. See '4.3.1 Floating-point numbers'
for more information about floating-point numbers and integer numbers.
4.8.5 Multiplication
To multiply a global variable with an integer number, use
$<global variable name> *= <integer number>
To multiply a global variable with a floating-point number, use
$<global variable name> *= <floating-point number>
To multiply a global variable containing an integer value with
another global variable also containing an integer value, use
INT $<global variable name> *= $<global variable name>
To multiply a global variable containing a floating-point value with
another global variable also containing a floating-point value, use
FLOAT $<global variable name> *= $<global variable name>
Use the same method with local variables and any combinations
of global and local variables. See '4.3.1 Floating-point numbers'
for more information about floating-point numbers and integer numbers.
When you have done that, change this line 'DEFINE MISSIONS <number of missions>'
and add this line 'DEFINE MISSION <mission number> AT ££Mission<mission number>'
.
Adding code in the MAIN part of the code for starting the new mission is also
a good idea :-)
You should NEVER EVER remove lines with the DEFINE OBJECT command
because you must then change ALL the commands in the mission script
that access these objects by their numbers. If you need to add an
object, add it to the end of the list and then change the total
number of objects defined.
------------------
5 Mission coding for newbies and retards :p
You got the mission builder. Got it running yet ? If not, look into
'2 Installation' and '2.1 Starting the mission builder'.
When you got it running, read and learn all parts of this readme.
Learn it twice.
OK, that part done. Now, load up the Stripped_complete.txt file
from the 'Stripped scripts' directory. Can't find the 'Stripped
scripts' directory ? It's where you installed this mission builder.
You're reading this readme, so you just SHOULD know where it is.
OK, we got a script loaded. Now we need some coordinates. Load up
the readme to my 'codecreator'. It's in the 'CodeCreator' directory.
When you have read the readme to the codecreator, you know how to
get those coordinates.
Lets create a parked car. How ? You should not. You read this
readme didn't you ? This readme says: "write parked_car and press F1".
So, do that, and create a parked car. In case you don't get any
parked car, make sure you have found the
'014C: set_parked_car_generator $Car cars_to_generate_to 101'
and make sure it is set to generate 101 cars. Still no car ?
Did you start a new game or load a saved game ? You can't load a saved
game. If you still haven't got any car, read the lines below, it says
'6 Support'. That should do it. :-)
------------------
6 Support
Just go to
http://www.gtaforums.com for
for all the support you'll ever need.
My web sites:
http://home.c2i.net/barton49
http://home.no.net/barton57
http://home.no/bobby-stalefish/
-----------------------
7 Changes
Changes since v1.2:
- Keywords added to the opcode search function.