Jump to content
Gunter Severloh

Lock object transformation coordinates

Recommended Posts

Question,  im trying to manipulate an object (plate of armor from a tank) to make fit and sit next to another plate and when i spin it,

its where i want it to be however as soon as i touch it to move it, it snaps back to its original position.

 

The object transformation part of when you edit an object, can i put specific numbers

for position and rotation and it would stay there or is there another method to lock an object in place?

    Like say i oriented the object to where i wanted, is there a way to get those numbers from that position and

keep it so it dont move or snap back to its default position?

Share this post


Link to post
Share on other sites

I think I know the problem you're talking about. Try setting the translation from world to model and then click and drag the arrows (red/green/blue) to move it.

Share this post


Link to post
Share on other sites
1 hour ago, beno_83au said:

setting the translation from world to model

Thanks for your reply beno_83au,

so your saying change the global and local coordinate space for the transformation widget, to the box which is the model?

 

      I have it set on the global the globe icon and i can manipulate the objects with the red/green/blue arrows already, and it will stay,

however once i have the position set and want to raise/lower or move forward or back that object then the object snaps black into its

original position then i have to redo it over again and compensate for the distance that is needed which takes

a few to several attempts to get it right.

 

I'll try the model and see what happens, thanks for the suggestion.

 

Edit..

So after messing with the control for a bit im able to switch back and forth between raising, lowering, turning,

and adjusting the object for rotation, i think this will do the trick, even though i was switching or toggling through

these already apon pressing the keyboard, i never used the second function for raising, and moving in and out.

    Its interesting after all these years the things you still seem to learn in this game. Thanks 🙂

  • Like 1

Share this post


Link to post
Share on other sites
19 hours ago, Gunter Severloh said:

Question,  im trying to manipulate an object (plate of armor from a tank) to make fit and sit next to another plate and when i spin it,

its where i want it to be however as soon as i touch it to move it, it snaps back to its original position.

 

I've had this exact problem bug the living crap out of me.

2 hours ago, Gunter Severloh said:

So after messing with the control for a bit im able to switch back and forth between raising, lowering, turning,

and adjusting the object for rotation, i think this will do the trick, even though i was switching or toggling through

these already apon pressing the keyboard, i never used the second function for raising, and moving in and out.

    Its interesting after all these years the things you still seem to learn in this game. Thanks 🙂

I don't understand the solution.  What is the second function for raising, moving in and out?  How do you prevent snapping back to original rotation?

Share this post


Link to post
Share on other sites
44 minutes ago, johnnyboy said:

What is the second function for raising, moving in and out?

What i normally do and the part of it im about to explain which i never used was based on one control,

so under controls then under development (editor controls) then buldozer select.

 

    I have set this control to my space bar, so doing this when you press the button whatever you allocate it to while an object

is selected you will get the circular xyz at start, this will rotate the object in whatever direction you want, press the control again
and it will raise, lower, and move back and forth the same object.

 

    At the same time you want to switch the Toggle Widget coordinate space (on the toolbar) from world or global to model (the box),

although im finding it just reverse everything but i need more testing with it.

44 minutes ago, johnnyboy said:

How do you prevent snapping back to original rotation?

You dont, you will use instead as described above, doing this it cut the time in half for me for my project,

so you just switch with the press of a key to the next xyz coordinate which allows you to move the object up, down, and back and forth.

You can still rotate the object how you want, just dont move it using the normal method to move any object in the editor.

 

I had asked Rydygier to view my thread here and this is what he had to say:

Quote

Ah, 3D vectors/geometry + absolute vs relative... A Pandora's Box of problems and headaches... Are you sure, you want to hop into this dark hole? 🙂

 

If you have already set everything in editor, then maybe only attachTo is needed but I do not know, if attachTo will keep set rotation/vectors as intended.

Rotated objects snapping back in EDEN at any movement know and curse myself. I know no solution inside EDEN except for "never move after rotating" rule.

Luckily for me, I rarely need to do anything of that sort in EDEN.

 

Other methods to rotate/position will be scripted one, there are commands and functions for it, but I really hate vectors manipulation, highly confusing.

Anyway, at the end it is the same question: will attachTo work, as desired.

 

If not... I can't think about anything else but per frame loop with some math keeping objects together in real time. I wouldn't recommend that way.

My response 1st paragraph via our pm

  "Ya the attachto works, i'm using the call BIS_fnc_attachToRelative;

for all pieces, it works once you preview and go ingame, just that while in eden i figured there has

to be a better way to rotate something and have it stay and not take longer then necessary."

  • Like 1

Share this post


Link to post
Share on other sites

Thanks man!  I get it now.  My main problem is I never tried or used the Translation widget when moving things.  I would use normal cursor select move and move something.  Then use the Rotation Widget to rotate it.  Then try and use normal cursor select to move it again, and then it snaps back and loses rotation.  I feel pretty dumb, as I wasted a lot of time not knowing this.

  • Like 1

Share this post


Link to post
Share on other sites

Yeah lol, it's such a frustrating thing. Glad you got it sorted though now 🙂

  • Like 2

Share this post


Link to post
Share on other sites
2 minutes ago, johnnyboy said:

I feel pretty dumb, as I wasted a lot of time not knowing this.

Same, and all along i was using the widget for all these years without even touching the xyz aspect of up/down/forward/back

just the rotate which is funny now that i think of it because i could have done so much more and different things

on my mission here https://forums.bohemia.net/forums/topic/223874-desert-ops-run-tactical-arena-v120/

which has 1,708 objects 🙄

 

I think tbh this editor is awesome compared to some editors i've used in other games, back in RO1 (Red orchestra Ostfront 41-45)

the game uses the unreal engine, which had an editor, it had a 3d component to it, but unlike Eden which is more up to date, things are way

easier to manipulate and get to where and how you want, add in some code and its even better.

10 minutes ago, johnnyboy said:

My main problem is I never tried or used the Translation widget when moving things.

Now you have an idea based on my own lack, lol, i suppose i could have just not bothered creating a thread for this but

asking and beno_83au pointed out the colored arrows which i had already used but not the other part, so i guess you can say

it made me look at what i never did, and or tried.

Regardless the objects will snap back but once you mess with the object a few times using the arrows and switching back

and forth from rotation to up/down etc,. then you'll get the hang of it.

    The controls i have setup below are what do this, no need to click with your ms cursor on the widget buttons, the keymap key

will switch on the fly, saving you some time.

1 hour ago, Gunter Severloh said:

so under controls then under development (editor controls) then buldozer select.

 

The whole snap back to original position makes you want to :smash:😄

  • Haha 2

Share this post


Link to post
Share on other sites

Also, when dragging using the arrows I've noticed that if you move the cursor off-axis from the arrow, the movement will go awry. So you've gotta drag along the arrow's axis, if that makes sense.

  • Like 1

Share this post


Link to post
Share on other sites
On 6/13/2021 at 10:36 AM, beno_83au said:

Also, when dragging using the arrows I've noticed that if you move the cursor off-axis from the arrow, the movement will go awry.

Yup, bringing this back up again as i shot myself in the foot not thinking about this when moving a built

vehicle with misc objects attached to it.

I must have spent 3-4hrs on this vehicle, everything works fine and as it should and then what do you know, i highlighted the whole thing

and go to move it in place in a certain lineup with my other vehicles, and what happens ....:face_palm::smash:

every object and about 23 of them flips back to their default position, WTF!

Then i come back here and reread your post even though i knew this its like a kick in the head to make me think that this is the only way

to move vehicles, or objects overall that have been manipulated to be set in a direction they are not by default.

    idk why i did not realize this, but i will need to make sure i let my subscribers know about this when they place the vehicles in their missions.

 

What a freaking headache why isn't there something in the editor to lock objects in place, there should be

Toggle Widget coordinate space lock, it should not automatically snap back to its default orientation, i think we need to request this

unless im missing a setting in the editor, granted i haven't and dont use everything.

  • Haha 1

Share this post


Link to post
Share on other sites

Nice! :thumb:

You know i had used 3Eden Enhanced with some missions i built and released on the workshop, i had never thought to use it

with my current project, if R3vo is up to making it possible to lock objects somehow which i would have no idea how that would be even done

i would seriously be all for using it.

   Only issue i see adding a function to a mod like 3Eden Enhanced is that even though it dont create any mod dependencies in a mission

not everyone is using it, thats why ideally imo the function should be in the base editor, but i guess we need to start somewhere.

 

   Cant imagine how much time it would save someone to just be able to lock something in place no matter how you manipulate, or move

the thing it may be attached too if that is the case, by default imo it should be in the editor to begin with, i mean im not asking for an overhaul here

just asking to make it so objects dont move and or snap back to their original position after you adjusted them to how you want,

BI should add such function.

    Again is there a setting or tool already in the editor that does this that i haven't found?

Share this post


Link to post
Share on other sites
9 hours ago, Gunter Severloh said:

Again is there a setting or tool already in the editor that does this that i haven't found?

Not that I've ever known of. 

 

You're right that it would be best as a vanilla feature. But Revo has been pretty active, and like you said there's no dependencies with 3den Editor, which is a huge bonus. I'm always running it. 

Share this post


Link to post
Share on other sites

Hello,

 

I've looked into the issue with rotating objects around z axis and I'd like to forward it to the devs first since @Dedmen recently also fixed the translation widget. Depending on the answer I'll then try to investigate if that is reliably fixable via SQF.

Here's the Ticket. Feel free to add some more information.

 

 

  • Like 1
  • Thanks 2

Share this post


Link to post
Share on other sites

Thanks R3vo for creating that ticket i think its a real issue even though its minor.

   I may record a short video demonstrating the issue myself but we'll see, ideally the issue doesn't happen with the arrows, it happens when you

rotate an object using the arrows, and then when you are not using the arrows, the object snaps back into its default, or original position

as soon as you move that object.

    An example would be like a tail gate of a truck, in the editor under objects when you place it, its normally upright, well say you wanted to

use that object for something else, like as a table, or as a barrier to something, so when you use the arrows to change the objects

rotation to say flat, or to something else other then what the object was when it was originally placed, as soon as you decide to move that

object from the new position that it was rotated at, it snaps back into its original editor placed position or orientation,

so you placed it upright when you chose it and when you moved it after rotating it ect,. it snapped back to that position.

 

    So unless there is a lock the object in place and then you can move the object with your mouse cursor, or theres

something with the rotation aspect that makes your change in orientation permanent unless you press undo, then

then it becomes a waste of time for the creator.

 

    The other issue with solving this is, if you simple are adding or enabling lock in the editor, it has to be permanent unless

you decide to change it yourself, so if you create something and then publish it on the workshop, someone gets it in the editor on their end

and then they move it to where they want for their mission or what have you, and the object returns to its original position and orientation, then the

lock cant be limited to just something you do on your end, it cant be something the would be subscriber, or user of your work has to turn on for a setting

it has to be something that is changes on everyone's end.

 

Or like in 3Eden enhanced when you add a function to something, its written to the mission.sqm and becomes permanent unless the creator updates it.

I hope this is a simple fix, or tweak or function that changes this, as its annoying as hell to work for 1-4hrs on something placing objects and have them all

flip back to their original orientation, basically you starting over. Its a big OMFG after all that work!

  • Like 2

Share this post


Link to post
Share on other sites
On 6/12/2021 at 7:34 PM, Gunter Severloh said:

its where i want it to be however as soon as i touch it to move it, it snaps back to its original position.

Click the button to disable snapping to terrain. Then you can drag+move it around without resetting rotation.

 

What it does when you move it is it rotates itself to follow the terrain. Which is what you would want when you have terrain snapping on.

  • Like 1
  • Thanks 2

Share this post


Link to post
Share on other sites
18 hours ago, Dedmen said:

Click the button to disable snapping to terrain. Then you can drag+move it around without resetting rotation.

Seen your message yesterday morning but had no time to take a look, but

im seeing what your saying,  man :face_palm: after all this time, and another editor lesson learned.

     So apparently its not a bug after all it was a setting all along and a simple one at that, and thats exactly what i needed to know,

idk how many times i looked at the wiki here https://community.bistudio.com/wiki/Eden_Editor:_Transformation_Widget

but the wiki to a point doesn't explain or really show different variations of if you do this, this will happen,

if you turn this off, and this on, this will happen sort of thing.

 

Im basically trying to do this

3den_moveXY.gif

 

after i do this

3den_widget_rotation.gif

but it keeps snapping to its original position after trying to move it normally,

well now i can by toggling vertical mode.

   You would think you wouldn't need to do that because in VR the terrain is flat, so what im not understanding

is why would the objects placed on another object, like plates rotated a certain way attached to a vehicle/tank

snap back to their original position if there is no deviation in the surface the vehicle is on?

 

I guess it dont matter at this point, now that i know what to do, and how it works.

     Thanks for explaining it with a different perspective Dedmen.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×