Home   Help Search Login Register  

Author Topic: an option in multi player setup  (Read 2142 times)

0 Members and 1 Guest are viewing this topic.

TERA_Forrest

  • Guest
an option in multi player setup
« on: 03 Apr 2004, 08:49:01 »
is there a way that i can have an option in the multi player "choose a side" screen to add one ai unit or delete a unit?

to be more specific... u somtimes see an option in the multi player screen for day, noon or night.  Thats kind of what i'm lookin for.

what i'm actually wanting to do is add an option to see the intro or skip it.  One trigger having the ai present would set off the other camera sequences and music.

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:an option in multi player setup
« Reply #1 on: 03 Apr 2004, 14:45:39 »
haven't tried this, but off the top of my head:
in the trigger that calls your intro, put condition:this and param 2==1
change the description.ext to some thing like:
titleParam2 = "Intro Movie:";
valuesParam2[] = {1, 2};
defValueParam2 = 1;
textsParam2[] = {"Intro On","Intro off"};

may take a little tweaking but thats the general idea where I would start working.

TERA_Forrest

  • Guest
Re:an option in multi player setup
« Reply #2 on: 03 Apr 2004, 19:43:49 »
thanks zombie... i'll give it a try

TERA_Forrest

  • Guest
Re:an option in multi player setup
« Reply #3 on: 03 Apr 2004, 19:48:02 »
this and param 2==1


when i try to put that into the "condition" field of the trigger i get an error "unkown paramitor" somthing or other, then the "typing line" goes next to the "2"

TERA_Forrest

  • Guest
Re:an option in multi player setup
« Reply #4 on: 05 Apr 2004, 07:13:01 »
bump

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:an option in multi player setup
« Reply #5 on: 05 Apr 2004, 13:36:51 »
ok, I believe you can remove the "this" part of the trigger
condition: param2 == 1
activation: [] exec "intromovie.sqs"{or whatever your movie is named ;) }

for no movie, no trigger required.

btw, you can make this a "zero trigger" also
axis a 0, axis b 0  activation none, once    and not have to worry about some ai to call the script

also in the movie script itself you could just add:
?(param2==2):exit
right at the beginning.

Once again, all of this is off the top of my head, I haven't tested it for errors but should get you pointed in the right direction   ;)

TERA_Forrest

  • Guest
Re:an option in multi player setup
« Reply #6 on: 05 Apr 2004, 22:09:36 »
thanks for the info Zombie, i'm still trying to figure out how to make the intro without triggers, it'll be some time before i come to this.

 :)

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:an option in multi player setup
« Reply #7 on: 06 Apr 2004, 13:07:39 »
your welcome!  If you would like, ther are 2 excellent tutes in the editors depot for making scripted cutscenes, which also work as intros and outros.  Start here: javascript:open_snippet('resource_view.php?id=50') then read this one:javascript:open_snippet('resource_view.php?id=557'), if you can get your brain around these 2 concepts, you'll be making great intros,outros,cutscenes.  Using triggers and attaching cameras to them never made sense to me, but the camera.sqs is very easy to use!  Enjoy!

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:an option in multi player setup
« Reply #8 on: 06 Apr 2004, 13:09:33 »
ummm, thought I put those hyperlinks in right, maybe not?  I tried to link to Snypers cutscene tute and Messiahs camera sqs tute.  Admin, help?!

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:an option in multi player setup
« Reply #9 on: 06 Apr 2004, 19:45:17 »
Best not to try linking to the open java applet.......just link to the page the resources are on.


Planck
I know a little about a lot, and a lot about a little.

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:an option in multi player setup
« Reply #10 on: 07 Apr 2004, 18:03:10 »
Description.EXT
Quote
titleParam1 = "DAYTIME";
valuesParam1[] = {1,2,3,4,5};
defValueParam1 = 5;
textsParam1[] = {"Sunrise","Midday","Sunset","Night","24hrs"};

titleParam2 = "GAMEPLAY";
valuesParam2[] = {1,2};
defValueParam2 = 1;
textsParam2[] = {"Intro ON","Intro OFF"};


INIT.sqs
Quote
;; intro array contains the names of all the units, vehicles and objects that you only use for the intro
eg
Introarray = [E1,E2,Chopper1]
;;;________PARAM1 & PARAM 2 OPTIONS SYSTEM___________________________
;;;________PARAM1________
;;NB>>> for thjis to work correctly, the map time set in the editor should be midnight

;;adjust the following skiptimestimes so that you get the sun just rising or just setting when you select those options
tx_Sunrise = 4.9
tx_Sunset = 18.8
?(param1 == 1):goto "SUNRISE"
?(param1 == 2):goto "MIDDAY"
?(param1 == 3):goto "SUNSET"
?(param1 == 4):goto "NIGHT"
?(param1 == 5):goto "24Hrs"
goto "GAMEOPTION"

#SUNRISE
skiptime tx_Sunrise
goto "GAMEOPTION"

#MIDDAY
skiptime 12
goto "GAMEOPTION"

#SUNSET
skiptime tx_Sunset
goto "GAMEOPTION"

#NIGHT
goto "GAMEOPTION"

#24Hrs
skiptime 12.0
?(local server):[] exec "skiptime\ServerSkiptime.sqs"
?!(local Server):[] exec "skiptime\ClientSkiptime.sqs"
goto "GAMEOPTION"

;;;________PARAM2________
#GAMEOPTION
?(param2 == 1):goto "OPTION_A"
?(param2 == 2):goto "OPTION_B"


#OPTION_A
Intro_On = True
goto "PARAM_END"

#OPTION_B
{deletevehicle _x} forEach IntroArray

goto "PARAM_END"
#PARAM_END

?(Intro_On): [] exec intro.sqs

Intro.sqs
Quote
;;Do whatever your into needs too and then at the end add the lines
{deletevehicle _x} forEach IntroArray
exit

no need for triggers, just a simple boolean which in this case i named "Intro_ON"


and for your skiptime system, you need 2 scripts

Clientskiptime.sqs
Quote
?(local Server):exit
newTime = false

#start
~ random 1
?(newtime): goto "NEXT"
goto "START"

#NEXT
_serverTime = currentServerTime
_timeChange = _serverTime - daytime
skipTime _timeChange
newTime = false
goto "start"

Serverskiptime.sqs
Quote
?!(Local Server):Exit
newTime = false;PublicVariable "newTime"

#start
_count = 0
#Loop
_count = _count +1
~2.5
skiptime 0.012
?(_count >= 2): goto "Update_clients"
goto "Loop"

#Update_clients
currentServerTime = daytime; PublicVariable "currentServerTime"
newTime = true; PublicVariable "newTime"
goto "Start"
Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

TERA_Forrest

  • Guest
Re:an option in multi player setup
« Reply #11 on: 30 Apr 2004, 08:03:21 »
i finaly got to the point of using this... *huff!

it works great! thanks alot guys!