Results 1 to 5 of 5

Thread: how to make a script

  1. #1

    how to make a script

    how do i make a script?

  2. #2
    Hey Wero,
    Lets start with a tool you will need first:
    Install it, and then when you run it, there are various types of scripts depending on what you want to do in the game.

    you have
    -SQF and SQL scripts that have various functions, those I really can go into, theres members that would know more then I.
    -Briefing scripts for briefings
    -Descriptio.ext scripts for mp
    -Init scripts and I could go on.

    Mission Editing and Scripting Information

    Scripting Commands by Functionality

    This may help you:
    Basic Scripting Tutorial


    Examples of scripts you can try out, and make yourself:
    Script Examples

    I would have to say in my opinion that understanding the editor and knowing how to create a basic mission properly,
    and implement codes, and then be able to apply scripts, is to learn how to use the editor, this would help you get a clearer picture of how the scripts work ingame.
    Mission Editor

    Mission editing Newbie FAQ

    Armed Assault Editing Guide - Deluxe Edition - English version

    Theres alot of members here that can really help you in various directions that know how to create scripts and such,
    but as i said really all depends on what you are looking to do.
    hope that helps.
    WarMod Series - A Massive Addon & Mod Customizable Compilation mod for Arma1, Arma2,CO & soon Arma3
    Mission Repository - Hosting Missions & Files for Iron Front: Liberation 1944
    WW2Epic - A Compilation Archive of Photos, Music, Videos, & References of WW2
    AI Compilation List of Addons/Mods/Scripts & Misc for Arma3

  3. #3
    ok thank u

    ---------- Post added at 23:23 ---------- Previous post was at 23:21 ----------

    would it let me make rpg type scripts?

  4. #4
    You can make any type of script you want, provided you have an idea, or know how.
    I would hope that some of the scripting masters around here would see the thread here and
    further help you as my knowledge is limited in script building especially from scratch.

    A good way to learn as been said by numerous scripters, and reg people alike on the forums here, is to find a script, or something that does what
    you want and then open it up and see how its done, learn by example.

  5. #5
    OK, let's say you have an enemy vehicle placed on the editor. That vehicle is a Shilka. Let's say you also want it to respawn at the same place it was before, and you only want it to respawn 5 times and 5 minutes after it has been destroyed.

    So place your shilka in the editor and in the init line write the following:

    nul = [this, 5, 300] execVM "spawnshilka.sqf";
    You'll understand what is written inside the brackets (array) later so i recommend you to download Notepad ++ from the web first.

    As soon as you've installed notepad ++ create a new file. Now next you need to pass the arguments of what you written inside the brackets of the init line of the shilka to the script. So you need to use the select command. It allows you to select arguments from the array that is calling the script:

    _veh = _this select 0;
    _lives = _this select 1;
    _delay = _this select 2;
    _type = (typeOf _veh);
    _dir = (getdir _veh);
    _position = (getpos _veh);
    So now you've selected arguments from the calling array and got extra assigned variables to be able to use BIS_fnc_SpawnVehicle. It will spawn a crewed vehicle. See here:

    Let's keep going with our script:

    private ["_veh","_lives","_delay","_type","_dir","_position"];
    _veh = _this select 0;
    _lives = _this select 1;
    _delay = _this select 2;
    _type = (typeOf _veh);
    _dir = (getdir _veh);
    _position = (getpos _veh);
    _loop = true;
    while {_loop} do {
      if (!alive _veh) then {
        if (_lives == 0) then {
          _loop = false;
        } else {
          _lives = _lives - 1;
          sleep _delay;
          deletevehicle _veh;
          _veh = [_position, _dir, _type, EAST] call BIS_fnc_spawnVehicle; 
      sleep 1;
    Ok if you want to learn, take a look at the script, and take a look here :

    Browse through the commands i'm using in the script i wrote, and try to understand what is going on. Feel free to post your doubts and questions.
    Arma 3 and xAItment.

    1 Sentence. 1 Erection. 1 Jizz.

    Please vote for this:

Similar Threads

  1. How to make Explosives script?
    By ssm4862 in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 3
    Last Post: Jan 29 2011, 23:15
  2. Help to make a script
    By PicVert in forum OFP : CONFIGS & SCRIPTING
    Replies: 2
    Last Post: Nov 26 2003, 02:28
  3. Help needed to make a script
    By PicVert in forum OFP : CONFIGS & SCRIPTING
    Replies: 6
    Last Post: Nov 24 2003, 11:15
  4. How do i make a script?
    By kimble275 in forum ADDONS & MODS: COMPLETE
    Replies: 1
    Last Post: Apr 14 2002, 12:54
  5. How do i make a script?
    By kimble275 in forum OFP : MISSION EDITING & SCRIPTING
    Replies: 1
    Last Post: Apr 14 2002, 12:54

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts