Home   Help Search Login Register  

Author Topic: Serious Help Needed With CamCreate Please  (Read 1740 times)

0 Members and 1 Guest are viewing this topic.

Offline jeffs

  • Members
  • *
  • I'm a llama!
Serious Help Needed With CamCreate Please
« on: 26 Feb 2003, 18:03:07 »
I'm running one of my typical training maps for our squad.  Instead of the typical targets I use I've decided to camcreate east units.  Works like a complete charm... Until multiplayer.  The men do not appear to die unless the player looking at them shoots them.  I.E.  I can kill the camcreated men, and see them die, but the guy next to me still sees them standing there.  Any help would be appreciated.  Part of the script is below:

hint "Welcome to the VASF Rifle Qualification Range"
~3
hint "You will have One 30 round Magazine to Engage 20 targets in the standing position, and One Thrity Round Magazine to Engage 20 Targets in the prone position"
~5
Hint "Scan Your Sector and Engage at Will"
~3
soltar1 = "SoldierEB"  camcreate getmarkerpos "q_1"
~5
soltar2 = "SoldierEB"  camcreate getmarkerpos "q_2"
~5
soltar3 = "SoldierEB"  camcreate getmarkerpos "q_3"
~5
soltar4 = "SoldierEB"  camcreate getmarkerpos "q_4"
~5
soltar5 = "SoldierEB"  camcreate getmarkerpos "q_5"

Any help would be greatly appreciated.

JeffS

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:Serious Help Needed With CamCreate Please
« Reply #1 on: 26 Feb 2003, 18:20:04 »
Have the script you run to camcreate the AI, run only on the dedicated server


by typing the following line at the start of the script

?!(local Server): exit

I think you would have to create a gamelogic called "Server" too


Often different clients see different things if tasks are being performed by them.

So for the more important things like scoring and veh respawn use server side scripting


This may be your problem, try it and see
Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

Offline jeffs

  • Members
  • *
  • I'm a llama!
Re:Serious Help Needed With CamCreate Please
« Reply #2 on: 26 Feb 2003, 19:38:45 »
Terox,

I added the "?!(local Server): exit" to the begining fo the script.  Didn't seem to solve problem.  I'm not familiar with game logic, coul you please explain that part?

Thanks,

JeffS

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Serious Help Needed With CamCreate Please
« Reply #3 on: 27 Feb 2003, 00:43:39 »
The problem with camcreate in MP is that it will tend to only create the object on the machine the command was run on (in this case the server).

I suggest using createvehicle (or createunit in this case) instead, and disabling the AI

Offline jeffs

  • Members
  • *
  • I'm a llama!
Re:Serious Help Needed With CamCreate Please
« Reply #4 on: 16 Mar 2003, 23:15:33 »
Sui,

createvehicle worked well on the troops, everyone can see them when they are shot.  Now however, they are duplicating when the trigger is tripped.  I.E. It makes two soldiers instead of one.  Any Ideas?

Thanks,

JeffS

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Serious Help Needed With CamCreate Please
« Reply #5 on: 17 Mar 2003, 00:39:06 »
Hey JeffS ;)

What is happening there is your script is being run twice. Once on the server, and once on the client. What you need to do is get the client to stop running it.

To do this, you'll want to do what Terox suggested. Add the line to your script (which I gather you've already done), and place a game logic unit.

To do this:
  • Hit F1 and double click on the map... just like you were going to place any other unit
  • In the Side dropbox (the one where you can select West/East/Resistance etc.) select "Game Logic"
  • Now you'll have a game logic unit. Name it Server
It doesn't matter where you place this unit on the map. It is invisible, and the AI (or the players) won't even see it, let alone react to it. It's simply there to make sure the script can tell the server from the clients ;)

If you manage that, you should be getting only one unit created when you run the script.

Offline jeffs

  • Members
  • *
  • I'm a llama!
Re:Serious Help Needed With CamCreate Please
« Reply #6 on: 17 Mar 2003, 01:21:31 »
Thanks a TON Sui

Nasty Buttler

  • Guest
Re:Serious Help Needed With CamCreate Please
« Reply #7 on: 17 Mar 2003, 01:56:25 »
the better way to do it is to stop the script from being run at all on the client machines.....the way to do that is to change the condition in the trigger running the script to this

condition ::>   MY condtions && local SERVER

hope this also helps.....its abit more efficient to not run a script on a client machine only to be booted out, its trivial i know but think about it then your doing this 500 times in a single mission, because then it might increase the overall performance of the mission....