Jump to content
Sign in to follow this  
bloodxgusher

Small Script

Recommended Posts

Well, heck.

waitUntil {player (in HeloTransport)};
[HeloTransport_pilot] join player;
waitUntil {!(player in HeloTransport)};
[HeloTransport_pilot] join helo_group;

That ^ does not work. The helo does not even spawn now. I am messing with it.

EDIT: Ooops! I forgot I added the perentheses to the code while here in the forum, and I copy and pasted into the sqm. Sooo, this,

waitUntil {player (in HeloTransport)};

does not work, but the bottom does,

waitUntil {player in HeloTransport};

So, now I am more confused about the use of perentheses.

Edited by CyOp

Share this post


Link to post
Share on other sites

Ok. So here is the scenario.

I have a driver who is the assigned driver of a vehicle. There are various way points that I have attached to the Driver then he uses the vehicle to drive to those waypoints.

On some of the waypoints i have effects that display text using the effects option that comes with the waypoint. I intend to use this like a trigger where when someone walks through the trigger or waypoint he or she will have the text display.

My problem with this set up is when I host this on a server. Every player who passes through or makes it to a waypoint, the text gets displayed for every player connected to the server.

I have no clue how this can be since I have no event handlers or anything of the sort that would broadcast the text. Are triggers and waypoint meant to do such?

What I simply want is the passengers ((Passengers being the players who connect to the server)) of the AI driver who is constantly driving in a circuit set by way-points to be the only people who can see the text once they make it to the way-point. Anyone have a procedure on doing this?

Thank you for reading this. :)

kylania did you create anything like this in that mission.sqm you sent me?

Share this post


Link to post
Share on other sites

Yes, that's exactly what the script does. As it passes each waypoint it tells players in the bus what stop it is.

As for using ( ), you can use them anytime you want to separate values or ensure order of operation.

Like:

!player in vehicle

could possibly be interperted as "whatever is not a player but is in the vehicle" when what we wanted was "when the player is not in the vehicle." So we put ( ) around the in command to make sure we execute that first then check if it's not. So:

!(player in vehicle)

says "Is the player in the vehicle? If not..." since it evaluates what's in the ( ) first.

Share this post


Link to post
Share on other sites
Yes, that's exactly what the script does. As it passes each waypoint it tells players in the bus what stop it is.

As for using ( ), you can use them anytime you want to separate values or ensure order of operation.

Like:

!player in vehicle

could possibly be interperted as "whatever is not a player but is in the vehicle" when what we wanted was "when the player is not in the vehicle." So we put ( ) around the in command to make sure we execute that first then check if it's not. So:

!(player in vehicle)

says "Is the player in the vehicle? If not..." since it evaluates what's in the ( ) first.

Bit of a nooby question Kylania...That Mission.Sqm you sent me. How do I load that in the game? Just create a random mission then repalce the mission.sqm you sent me with the one I just randomly created? Or is there another proces?

Share this post


Link to post
Share on other sites

Copy the BusDriverBill.Chernarus folder (with the sqm inside it) into your My Documents\ArmA2 Other Profiles\<your arma name>\missions folder

Then open it in your A2/CO Single Player Editor and Preview. Hop in the bus when it stops by you to see the messages. Also notice how it doesn't stop with a fire fight happening nearby.

Share this post


Link to post
Share on other sites
Copy the BusDriverBill.Chernarus folder (with the sqm inside it) into your My Documents\ArmA2 Other Profiles\<your arma name>\missions folder

Then open it in your A2/CO Single Player Editor and Preview. Hop in the bus when it stops by you to see the messages. Also notice how it doesn't stop with a fire fight happening nearby.

Hey thanks for that. Now I see what you mean.

Something I want to know though. on the way points. I have been using the effects button at the bottom left when you go to edit the way point. Is there a way to use that while not having the effect go off for everyone in the server? or should I manualy add them in the condition/On act boxes in the waypoint with scripts like :waypointAttachVehicle, triggerText, You know, like I want the same effects to happen that the waypoint can give me with the Text fading instead of using the hint system.

Now one of my concerns is that this still wont work because the people who will be boarding the bus are all player controlled civilians. So I think that since they are not solders some of the same commands don't apply. In the editor. The driver is locked off to me as a solider and civilian so now im thinking it just may be the editor. When I ever I finalize my mission I still can get in as a civvy.

Again thanks for the insight. I will try this out tommorow when I get off work. :)

Share this post


Link to post
Share on other sites

Kylania. This driver thing is probably the most stuborn script i have come across. Seems When ever I host this I don't get the results I intended. You think you can do a test host to see if this works on multiplayer for you?

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×