Home   Help Search Login Register  

Author Topic: Why does this script not work  (Read 643 times)

0 Members and 1 Guest are viewing this topic.

Offline 456820

  • Contributing Member
  • **
Why does this script not work
« on: 09 May 2005, 20:06:23 »
Code: [Select]
#repeat
~2
gl1 setpos getpos player
grp4 domove gl1
~30
grp3 domove gl1
goto "repeat"

Thast my simple script its meant to move a game logic called gl1 over the plyer in a 30 second delay loop just one thing it doesnt seem to work is it beacuse of the way i have used the domove command.
obdviously grp4 and grp3 are a group name using grp3 = group this and so forth for grp4.

Anyway anyideas would be nice

Plus i have thought of the best way to make LST a good boat and a usefull one i havent heard anyone say it.
To make it move easily use setveocity and do move commands
and to make it fire just use
Code: [Select]
This addweapon "shell125"; this addmagazine "shell125in the lst init fied to give it a shell125 and ammo
then to make it firs use dotarget and do fire commands
Would that work if so HOORAY ive made the LST good plus you can also add other weapons to it like vulcan cannons and LGB

Offline The-Architect

  • Former Staff
  • ****
  • Bite my shiny metal...
    • Bob's Un-official Flashpoint Page
Re:Why does this script not work
« Reply #1 on: 09 May 2005, 20:11:06 »
Try

"_x domove (getpos _gl1)" foreach units _group4

Maybe it will work, maybe not.  ???
James Andrew Wilkinson 1977 - 2005 R.I.P.
"If it ain't the friggin' incoming it's the friggin' outgoing. Only difference is who gets the friggin' grease, and that ain't no friggin' difference at all."

Offline 456820

  • Contributing Member
  • **
Re:Why does this script not work
« Reply #2 on: 09 May 2005, 20:12:33 »
thanks for the quick reply i shall try because this is a very importans script for a sniper mission im trying to make enemy's hunt for the sniper

Offline dmakatra

  • Members
  • *
  • Better known as Armsty
Re:Why does this script not work
« Reply #3 on: 09 May 2005, 20:18:51 »
#repeat
~2
gl1 setpos getpos player
(leader grp4) move getpos gl1
~30
(leader grp3) move getpos gl1
goto "repeat"

Try that.

:beat: *Gets Shot* :beat:

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Why does this script not work
« Reply #4 on: 09 May 2005, 21:21:00 »
You've solved it twice Armsty, which sort of puts us back where we were before. ;D

move for groups
doMove for individuals
Plenty of reviewed ArmA missions for you to play

Offline dmakatra

  • Members
  • *
  • Better known as Armsty
Re:Why does this script not work
« Reply #5 on: 09 May 2005, 21:47:20 »
I did something good? Horray for me! ;D

:beat: *Gets Shot* :beat:

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re:Why does this script not work
« Reply #6 on: 10 May 2005, 04:41:34 »
Just one thingy here;

Why using unnecessary resources?

Think about, if you really need that gamelogic here.

Code: [Select]
#repeat
~2
(leader grp4) move getpos player
~30
(leader grp3) move getpos player
goto "repeat"

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted

Offline 456820

  • Contributing Member
  • **
Re:Why does this script not work
« Reply #7 on: 10 May 2005, 07:58:26 »
clever never thought of that plus it would probaly be less lagy that way but also wouldnt that make them follow the player all the time i want the game logic refreshed on the player every so often so theynver know ecactly where the player is

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re:Why does this script not work
« Reply #8 on: 10 May 2005, 21:59:42 »
About the lag - at this stage there won't be any noticeable
difference yet, but as we all know:

ppl tend to use already existing work instead of creating
everything from scratch again, so that in case of more complexity there will be off course at one point some performance difference - one day.

Also as OFP is limited in usage of groups or units, it's always
wise to reduce things to a minimum of resources, as every
gamelogic you can save here - will be one more free gamelogic
to be used there.

About them to follow the player all the time:

Nope - it will do exactly the same as when using the gamelogic,
as you only send them to the actual position of the player (or
in previous case the gamelogic) ... and nothing more.

:note - the loop's interval of 30 seconds has not been changed

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted