10-78 Duke 0 Posted January 2, 2007 Does anyone have a modified version of the Spectating script v1.2 by Kegetys which allows dead players to spectate only those players on thier side? This is a great script but in order to use it in our clan's internal ladder competitions we need a modification as described above. Any help would be much appreciated! Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 3, 2007 Thanks, Filer .....but this version doesn't allow for spectating your side only in a team vs team match either. Does anyone know if a modification of the original script is possible to achieve this? Share this post Link to post Share on other sites
strango 5 Posted January 4, 2007 it's a simple modification of this script: Remove the current line that sets the DeathCamArray and replace it with these two lines (assuming you have East Vs West). Fill out each of the arrays with players you want that side to spectate. <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> ?(Side Player == West): DeathCamArray=[W1,W2,W3,W4] ?(Side PLayer == East): DeathCamArray=[E1,E2,E3,E4] Share this post Link to post Share on other sites
Busterking 0 Posted January 4, 2007 Thank you for the reply Strango. Now, how can we also include disabling the seagull view in the script? Share this post Link to post Share on other sites
deFiler 0 Posted January 4, 2007 disabling seagullmode is not possible ..well only by chossing another respawnmode .. u can only force the player back in the dialog when he closes it by hitting the ESC-Key that might be done by replacing the line ? !dialog : goto "seagull" with ? !dialog : goto "start" but i am at work and cant test this right now .. deF edit: better download that again .. i fixed something that didnt need fixing .. messed with GUER and resistace again .. Edit: tested .. seems to work as expected .. drawback u can not get out of spectator .. not even to disconnect from the server .. u have to Alt+F4 then or wait for the next round .. Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 5, 2007 Thanks for all your help guys....will test tonight after work!! Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 7, 2007 it's a simple modification of this script:Remove the current line that sets the DeathCamArray and replace it with these two lines (assuming you have East Vs West). Fill out each of the arrays with players you want that side to spectate. <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> ?(Side Player == West): DeathCamArray=[W1,W2,W3,W4] ?(Side PLayer == East): DeathCamArray=[E1,E2,E3,E4] Have tried multiple times and this doesn't work. Can't figure out why....the method seems perfectly logical (could it be a syntax error?) All that happens when a person dies is they go to seagull mode. I tried flying high to force back into spec mode and I got this error: 'DeathCamCurTarget = (DeathCamArray l#l select _DeathCamIndex)' Error Zero divisor Thanks again for your help folks....maybe one of you can shed some light on this problem. Share this post Link to post Share on other sites
strango 5 Posted January 8, 2007 When I use the spectator script I have been modifying it to run from an action instead of seagull mode. When I run it from an action those commands work. Perhaps when in seagull mode it strips you of your side. If this is the case you may want to set an integer variable at the start of the mission based on the side of that client and then use that variable to determine which array to use. Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 8, 2007 That is exactly correct....checked in the biki....once dead your side is considered civilian. Could you elaborate on the integer thing.....I'm very new to scripting. Thanks! Share this post Link to post Share on other sites
strango 5 Posted January 8, 2007 Put something like this in init.sqs Do NOT do a publicvariable as you want the clients to maintain the values they get for a result. <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> ?(side Player == West): MySide = 1 ?(side Player == East): MySide = 2 Then change the array set to: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> DeathCamArray=[] ?(MySide==1): DeathCamArray=[W1,W2,W3,W4] ?(MySide==2): DeathCamArray=[E1,E2,E3,E4] Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 8, 2007 Thanks, I will test tomorrow after work!! Share this post Link to post Share on other sites
10-78 Duke 0 Posted January 9, 2007 SUCCESS!!! Thanks guys! Share this post Link to post Share on other sites
Unleashed2k 0 Posted May 28, 2007 Can anyone get this working in 1.06 (using 1.4) init line 9 ?(side Player == West): MySide = 1 Share this post Link to post Share on other sites