MOH Central

Medal of Honor Series Forum => MOHAA Series: General => Topic started by: Elgan {sfx} on December 22, 2005, 08:55:41 PM

Title: Release: Christmas Mod/Tree
Post by: Elgan {sfx} on December 22, 2005, 08:55:41 PM
Well, it started out as a christmas mod, now its mainly a christmas tree mod, It also has night, it had snow but i didnt finish it and its nearly christmas, so i recommend Ric-Hards, let it snow.

   

   

   Basicaly, you exec the mod, from your map file, with ::night or ::tree ( coord) ( angles ( pattern file).

   

   Now the pattern file, sets up how the tree looks and how the tree flashed. dont go over the top now. The settings are basicaly threads, and their parameters , allows you to tell it when, how, how long to blink, what to blink, what to spawnn, what colour etc. We all used AP at least once right?

   

   Here are some screenshots, The first was taken some days ago, and the second was taken of default settings just now.

   

   

   I will go right ahead and paste the readme now.

   

   Installation:

   -------------

   

   For AA:

   Place the christmas.pk3 and the tree.txt inside your main folder.

   

   For SH:

   Place the christmas.pk3 and the tree.txt inside your mainta folder.

   

   For BT:

   Place the christmas.pk3 and the tree.txt inside your maintt folder.

   

   The main,maintt,mainta folders are usualy found inside your MOHAA install directory.

   The default MOHAA installation directory is 'c:program filesea gamesmohaam'.

   

   This mod should be executed from your map script(s), from under level waittill

   spawn. For example:

   

           level waittill spawn

   

           exec christmas.scr::night    //- This will turn on night mode

           exec christmas.scr::tree ( -992.33 -2901.28 -90 )    //- This will spawn a christmas tree at coordinated ( -992.33 -2901.28 -90 ), with default angles, using default tree pattern file.

         

   This file contains two mods. night and

   a christmas tree mod. The christmas tree mod is

   the only mod that should be executed with parameters.

   The parameters are as shown below.

   

   Tree Mod:

   

       exec christmas.scr::tree ( vector ) Coord,  ( vector ) angle ,  ( String ) tree file

       exec christmas.scr::tree ( coords ) ( angle ) ( tree pattern file )

   

       Coord - origin where the tree should spawn. The coord must be given for a tree to spawn. This must be provided.

       Angles - Angles for the tree to take. If this is not provided, default angles of  ( 0 0 0 ) will be used.

       Tree File - This is the file to use for the tree's pattern. If this is not provided, tree.txt will be used.

   

   Night Mod:

   

       exec christmas.scr::night

   

       Place in a map script and it will be night in that map.

   

   

   Editing the tree, Make it look different, Make it flash different.

   ------------------------------------------------------------------

   If you wish to edit the tree, Open the tree.txt with any text editor. The one your using now for example.

   Then read what things are available. Scroll down until you see a list, It will say above the list "edit here for .."

   by adding and taking away lines from that list, you can create a new look for the tree. you can change the parameters of the

   lines to get different results. This is the same for the flashing. Note, Do not! put to any ringss, loops and spirals

   onto the tree, This may cause the server to crash.

   

   WARNING:

   ---------

   When editing tree.txt and setting up the look of the tree. test it on your home mohaa installation first.

   If you over do it, using too many spawns. The game will crash from too many lights.

   If you are spawning more than one tree, you must cut the number of lights that are spawned down by changing

   the number of loops, spirals and rings in the pattern list.

   

   Enhancing

   ---------

   If you wish to add mroe coronas. You will find in the christmas.scr there is a list of what coronas you can

   use. By adding to this list, the code has more coronas to pick from. You also must create a thread for that

   corona you added, using the same name , copy one of my threads and rename it, change the model. Only the corona

   models from AA are supported by default.

   

   If you have any questions or problems, feel free to contact me or ask in the forums.

   

   

   Download Here (http://www.cobra.funmodsforu.com/MODS/Christmas%20Mod.zip)
Title: Release: Christmas Mod/Tree
Post by: *Herr_Kruger on December 23, 2005, 02:21:09 PM
very nice, nice, nice elg :P
Title: Release: Christmas Mod/Tree
Post by: LeBabouin {sfx} on December 23, 2005, 02:34:55 PM
Best moh code i ever seen. Delightfull to read.
Title: Release: Christmas Mod/Tree
Post by: Elgan {sfx} on December 23, 2005, 02:49:37 PM
aw ty, probably the only moh code i tried to comment. half commented,m i got a lil lazy in places:P

   

   Some of the code for blinking could be improved also, as i reused alot of the same lines but did not create new threads to cut the size down. Hey, if it works,. why fix it:P

   

   

   I also forgot more from the readme!. I am useless with them.

   

   As well as the ability to effect the tree using the tree pattern files, You can use

   

   

   local.tree = waitexec christmas.scr::tre (coord)
   

   

   Local.tree would then be the tree, and you can effect it more. without editing the christmas.scr