OFPEC Forum
Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting General => Topic started by: mathias_eichinger on 22 Jul 2009, 21:06:43
-
Hey, lads, just tried to setpos a notebook on a table by using:
this setPos [(getPos this select 0),(getPos this select 1),1];
but it does nothing, the notebook remains firm on the ground.
Any ideas what I am doing wrong?
Thank you
Mathias
-
Hrrm, the code runs fine (checked with "Klapptisch" and "Notebook"). ???
-
Strange, this is exactly what I am trying to achieve....only that the Notebook remains on the ground only to jump on to the Klapptisch once shot at.
-
Not sure if this relates to your problem, but I've had similar issues with a setpos and setVectorUp combination, where the object simply couldn't be setpos's inside another object, a powerGenerator inside a building in my case.
The powerGenerator refused to be put partly under the floor at the same time as it was not aligned with the ground. Weird... don't know, annoying... yes.
-
I don't know what a klaptish is, but I've noticed one thing. Some objects are designed so that you can put other things on top of them, without falling through. Certain tables have this function for instance. Otherwise radios and other stuff would just sink to the floor after being setPosed. Now, if you try to set a brittle object like a radio on such a table, and miss the height by a fraction of an inch, so that the radio is partly inside the table, the radio will sometimes fly away in arandom direction. Try setPosing the object a couple of inches above the surface, and it will usually sink down to the ciorrect position. I noticed this in OFP. Don't know if it's still a valid observation in ArmA2.
-
Klapptisch == FoldTable (http://www.armatechsquad.com/ArmA2Class/Objects/furniture/full/FoldTable.jpg)
-
Your link produced the following error with SeaMonkey Worldeater:
Redirect Loop
Redirection limit for this URL exceeded. Unable to load the requested page. This may be caused by cookies that are blocked.
Planck
-
I don't know what a klaptish is, but I've noticed one thing. Some objects are designed so that you can put other things on top of them
This is very true and is also true when you try attachto with certain objects , i believe the folding table was one of the objects that i could not attachto ,meaybe wrong in this instance but there are seeming some classes that dont like setpos and attachto.
-
The more I hear the more I dislike. My favorite commands..setpos and setvectorup, nearly useless?
-
Nawwww, it works fine.
I just tried it with a road cone and a folding table.
Named the table 'mytable', and put 'this setPos [(getPos mytable select 0),(getPos mytable select 1),1];' in the road cones init field.
Placed the road cone in the same position as the table in the editor and then previewed in the editor, result was a road cone on top of the table.
Planck
-
But what of vehicles. Can they be setpositioned? In the terrain? Or did BIS revert to the old OFP object collision deal?
-
You mean like this:------------
Of course, if you get in and drive it, it will pop back up to the surface, just like in OFP.
Planck
-
Cool. Thats nice to know. Thanks Planck. Might wanna call a wrecker to get that twactor out of the mud now.
-
I just find it very annoying that units die a rather agonizing death if you happen to setpos them a couple of inches too high in a building, at least some buildings, haven't tried them all.
The stay levitated in the air, moaning and complaining even though nothing is touching them (except air) until suddenly, they die and shut up.
Looks rather funny, though I doubt this was intended by BIS.
Laggy
-
I've read somewhere there is a code that stops that collision. I believe it is used in things like Warfare base construction etc. Not sure if it's in the new RTE by ionos.