[Resources] - Introduction to Scripting

Discussion in 'Scripting Discussions' started by CommanderRetra, Jun 18, 2013.

  1. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    Fox, antirocket, Tankschaf and 5 others like this.
  2. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    ============================ Introduction ============================
    Engine (Real Virtuality):

    ArmA uses the Real Virtuality game engine. Real Virtuality has been developed for over 10 years. The engine has often been used in military training simulators all around the world and all of the Bohemia Interactive video games since Operation Flashpoint. The engine features realistic day/night cycles, varying weather, a view distance of up to 15 kilometres and these are just some of the minor aspects of the engine. Every weapon in the game fires projectiles with real trajectories, drop off and penetration characteristics, all data was gathered from testing each gun individually and measuring; the impact, range and bullet drop as accurately as possible.

    The performance of the engine is only limited to the performance of the computer. This gives users the freedom of having a wide range of different scenarios to be played. The engine calculates all events dynamically, this caries from unit’s speech, AI decisions and how they respond to different situations. One of the primary reasons as to why the Real Virtuality game engine is so special is because of it’s to give users the freedom to move their units head independently to their body/weapon. This simple feature adds realism, which many game engines miss by not adding such a simple feature. The engine is up to its fourth version (ArmA 3) since its initial release in 2001.

    Scripting language:

    Real Virtuality is a very open game engine, and with the scripting language it really opens up many possibilities. The game was designed to have the ability to edit it and mod it. The scripting language is heavily based upon bits and pieces of C#, C++ and Java. This language allows users to control and influence the behaviour of the game engine. The structure is similar to commonly used programming languages (C#, C++, Java). The scripting language was designed to be very simple yet limitless for the user/scripter. Realistically you don’t need any requirements or prior knowledge of programming, it’s designed to be practically idiot proof. All you need is patience and the will to learn.
     
    antirocket, Tankschaf, blur and 2 others like this.
  3. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
  4. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
  5. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
  6. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
  7. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    ======================= Community Resources ========================
    :cool: Reserved for the Community :cool:
     
  8. zyz0430

    zyz0430 New Member

    Joined:
    May 21, 2013
    Messages:
    12
    Likes Received:
    1
    realy nice! You just save me a lot of time to search for all kinds of tutorials .
     
    CommanderRetra likes this.
  9. Dusty Nuttles

    Dusty Nuttles Well-Known Member

    Joined:
    May 5, 2013
    Messages:
    305
    Likes Received:
    21
    Wow man, I've been waiting for a thread like this. Massive thanks!
     
    CommanderRetra likes this.
  10. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    It is now complete and is ready for suggestions, other examples, guides and stuff... Your input is appreciated :)
     
    Freaking Fred likes this.
  11. Hoplit

    Hoplit Well-Known Member

    Joined:
    Feb 21, 2013
    Messages:
    109
    Likes Received:
    4
    This is awesome! I'm looking forward to making my own simple scripts, and it helps me a lot! Thanks for making this. :)
     
    CommanderRetra likes this.
  12. Freaking Fred

    Freaking Fred OpenDayZ Rockstar!

    Joined:
    Feb 1, 2013
    Messages:
    380
    Likes Received:
    171
    You did a great job with this thread! This is an amazing resource for the community! It should be a requirement for server owners, that plan to add scripts to their server, to read through this thread.
     
    CommanderRetra likes this.
  13. Sandbird

    Sandbird Valued Member!

    Joined:
    Feb 1, 2013
    Messages:
    182
    Likes Received:
    39
    Best thread ever ! So glad i found it. The ArmA2.Script.Compiler.v.0.1 was something i need :)
    Just a quick question..even with the Compiler its a b....h to test code i've written...Isn't there a faster way to test stuff, for example when i create an igame menu right now i write the code, check it with the compiler for errors then i have to compile the mission, run the server, go ingame and see if it works...if not i gottta close the server edit it and redo the whole process again...making a simple comma error take 1.5m to test to see what the final result in game is :(

    From what i realized arma engine is not 'on the fly' code like PHP for example. Cant i just, i dont know...inject stuff and test it on the fly ? Like make a dynamic .sqf file that i can edit it on the spot and test ingame ?

    -Thanks
     
  14. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    Using the editor is probably the best thing to do but you could look on armaholic there might be something there.
     
  15. Sandbird

    Sandbird Valued Member!

    Joined:
    Feb 1, 2013
    Messages:
    182
    Likes Received:
    39
    Do you mean the Arma Editor ? Cause with that i could never preview the MP missions..i had to start a server and then join it to test...I wish i could preview the map as in SP...that would make it so much easier :/
     
  16. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    You can preview the MP mission in the editor by;
    1. Joining the server
    2. load into the game
    3. leave
    4. go to arma main menu
    5. press ALT + E
     
    Sandbird likes this.
  17. Sandbird

    Sandbird Valued Member!

    Joined:
    Feb 1, 2013
    Messages:
    182
    Likes Received:
    39
    Sorry to bother you again, but after today i'll either stop scripting or start screaming...Took me 8h to figure out a simple mistake in a function i wrote that was breaking Combat roll and i didnt know why. It took me forever to save/compile/load server/join with client/test the function.../quit/start all over again.

    You mentioned that we can test things in the Editor...Can i write for example a Rollout menu function...like,.. Dance for example, over fire....and test this on the editor ? Without running a server and join with a client ?
    Like actually having the .sqf open on my notepad, edit and save, then reload on the editor and hit preview ? oO (of cource loading the whole mission folder 1st, and editing the corresponding .sqf file from there.. )
     
  18. CommanderRetra

    CommanderRetra Yogi Bear|Moderator Staff Member

    Joined:
    Apr 3, 2013
    Messages:
    553
    Likes Received:
    157
    Yes you can although I suggest you just use the standard editor without dayz launched. So you would create a folder in your mission folder, and name it something like blah.Chernaurus
     
  19. Tankschaf

    Tankschaf New Member

    Joined:
    Jul 17, 2013
    Messages:
    11
    Likes Received:
    1
    THX for this wonderful collection!!! For newbies like me, its a awesome collection of knowledge!!!
     
    CommanderRetra likes this.
  20. andyuk

    andyuk New Member

    Joined:
    Aug 15, 2014
    Messages:
    1
    Likes Received:
    0

Share This Page