SteveTrek
Registered:1401389046 Posts: 10
Posted 1401389730
Reply with quote
#1
I'm working on a mission script, meant for multiple ships, where the players all start in grid A1 and have to reach the station in grid E5 before it is destroyed. I'm able to place Artemis just fine, but when the Intrepid spawns, it's showing up at the station in E5 instead of in grid A1. I tried forcing a second player "create" command for the Intrepid, and obviously that was a mess. Is there a better way to create and place the additional player ships, instead of just the one "create" command for Artemis? I really need this mission to work for at least 4 ships, since I usually have between 20-30 people playing. Presuming I need to keep just the one "create" command for the players, can I force additional ship spawns to happen in a particular location? Thanks for any help you can provide! -Steve
Xavier Wise
Registered:1375817447 Posts: 1,362
Posted 1401400120
Reply with quote
#2
Add this code to your script. It should be completely stand-alone (i.e. you do not need to add anything extra to what you have already written).<event name_arme="Event 1584" id_arme="638b88ba-24b8-4f8b-b8fc-95a032df6a49"> <if_exists name="Intrepid" /> <if_variable name="Place Intrepid" comparator="NOT" value="0.0" /> <if_variable name="Place Intrepid" comparator="NOT" value="1.0" /> <set_variable name="Place Intrepid" value="1.0" /> <set_timer name="Place Intrepid" seconds="5" /> </event> <event name_arme="Event 1585" id_arme="127ec914-120e-4a48-a4d8-d92971a859ae"> <if_variable name="Place Intrepid" comparator="EQUALS" value="1.0" /> <if_timer_finished name="Place Intrepid" /> <set_relative_position name2="Intrepid" distance="600" angle="240.0" name1="Artemis" /> <set_variable name="Place Intrepid" value="0.0" /> </event>
__________________ Fleet Captain Xavier Wise - TSN SabreLink to TSN RP Community Website Want to follow development of the TSN Sandbox? Head here:https://ko-fi.com/xavierwise
SteveTrek
Registered:1401389046 Posts: 10
Posted 1401404355
Reply with quote
#3
Excellent! I will give that a try tonight. Thank you kind sir!
SteveTrek
Registered:1401389046 Posts: 10
Posted 1401426375
Reply with quote
#4
I've tried it out, and it's still putting the Intrepid by the station. Here's what I'm putting in the XML: --------- <!-- Testing --> <!-- by SteveTrek --> <mission_data version="2.0" background_id_arme=""> <!-- ************************************************************ --> <start name_arme="Test Mission"> <!-- Players start in the upper left corner of the A1 grid --> <create type="player" x="90000.0" y="0.0" z="5000.0" angle="145" name="Artemis" /> <!-- Relay Station 173 placed in the lower right corner --> <create type="station" x="12000.0" y="0.0" z="80000.0" angle="0" name="Relay Station 173" raceKeys="Federation" hullKeys="base" /> <set_object_property property="canBuild" value="0" name="Relay Station 173" /> <!-- Create initial bad guys --> <create type="enemy" x="13731.0" y="0.0" z="77526.0" angle="145" raceKeys="enemy standard" hullKeys="large" fleetnumber="-1" /> </start> <event name_arme="Event 1584" id_arme="638b88ba-24b8-4f8b-b8fc-95a032df6a49"> <if_exists name="Intrepid" /> <if_variable name="Place Intrepid" comparator="NOT" value="0.0" /> <if_variable name="Place Intrepid" comparator="NOT" value="1.0" /> <set_variable name="Place Intrepid" value="1.0" /> <set_timer name="Place Intrepid" seconds="5" /> </event> <event name_arme="Event 1585" id_arme="127ec914-120e-4a48-a4d8-d92971a859ae"> <if_variable name="Place Intrepid" comparator="EQUALS" value="1.0" /> <if_timer_finished name="Place Intrepid" /> <set_relative_position name2="Intrepid" distance="600" angle="240.0" name1="Artemis" /> <set_variable name="Place Intrepid" value="0.0" /> </event> </mission_data> ----------- Very simple, but it doesn't seem to be working. I'm following the process of starting the game with the Intrepid main screen selected, but not "Ready to play", I then pause the game, set Intrepid to "Ready", and then I resume the game and set Artemis "Ready". I've tried a few variations, but I always seem to get the same result. What am I doing wrong here? -Steve
Xavier Wise
Registered:1375817447 Posts: 1,362
Posted 1401446415
Reply with quote
#5
I was fairly certain that that would work. Try adding the following to your start block:
<set_variable name="Place Intrepid" value="2.0" />
__________________ Fleet Captain Xavier Wise - TSN SabreLink to TSN RP Community Website Want to follow development of the TSN Sandbox? Head here:https://ko-fi.com/xavierwise
SteveTrek
Registered:1401389046 Posts: 10
Posted 1401564454
Reply with quote
#6
That addition to the start section worked! I guess it just needed that variable defined. I also found that I could force the Intrepid into grid A1 if I put a station there. Apparently the subsequent ships will populate around the first station you define. I'll have to do more tests to see how well that holds true. Thanks for your help! -Steve