Jump to content


Photo

Origins of prefab func_static parts don't rotate properly

origin rotate rotation func_static prefab build

  • Please log in to reply
26 replies to this topic

#1 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 18 December 2017 - 03:45 PM

I changed an existing prefab (mirror on stand) to be a larger floor standing version. I saved it as a prefab from origin 0,0,0 and it appears fine in the prefab viewer etc.

However, when i import it into my current map and rotate it, one part rotates the origin correctly but the other two still remain oriented in the XYZ direction and don't rotate accordingly.

 

It means the tilting is at a crazy angle.

 

How can i set the correct origin rotation on the two parts and make it stick?

 

thank you.

 

Attached File  origin rotations.JPG   21.22KB   0 downloads



#2 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19843 posts

Posted 18 December 2017 - 03:59 PM

You create a nodraw brush and make i a func_mover like a door or handle, then you bind the mirror two it - I think maybe the func_mover is missing from the prefab?

 

I originally made that prefab, and to be honest we need a batter 'mirror' material. The silver serving tray I used has a broken material, it reflects everything at the wrong angle.

 

What we need is -

  • An actual desktop and floor standing mirror model
  • A replacement mirror texture

Another issue existing the reflection is very perf heavy, so either the mapper has to be carefull where they place it, or we come up with two textures full reflection and fake reflection.

 

We would need help from a modeler and a team member.



#3 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 37101 posts

Posted 18 December 2017 - 04:33 PM

I changed an existing prefab (mirror on stand) to be a larger floor standing version. I saved it as a prefab from origin 0,0,0 and it appears fine in the prefab viewer etc.

However, when i import it into my current map and rotate it, one part rotates the origin correctly but the other two still remain oriented in the XYZ direction and don't rotate accordingly.

 

It means the tilting is at a crazy angle.

 

How can i set the correct origin rotation on the two parts and make it stick?

 

thank you.

 

attachicon.giforigin rotations.JPG

 

Are you using the most recent version of DR?  Prefabs should be created already merged as a group, which means they should rotate together.



#4 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19843 posts

Posted 18 December 2017 - 04:41 PM

Are you using the most recent version of DR?

2.4.0 had a bug where items would sometimes get rotated separately(I never go around to logging a tracker), I wonder if that's been fixed in 2.5.0pre1..? if not will log a a tracker etc.



#5 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 18 December 2017 - 05:01 PM

I am using DR 2.4.0 x64.

They do come in grouped but two out the three components don't rotate properly.

 

And B1k3rdude is another chap i'd like to thank regarding video tutorials. Learnt alot watching them, cheers.



#6 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 18 December 2017 - 05:04 PM

I did also make a mini version of what B1k3rdude compiled as a prefab. That and his original do the same thing.

Maybe it is a DR thing?



#7 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 37101 posts

Posted 18 December 2017 - 07:04 PM

When things are in a group, they appear blue when you select them.  It doesn't look like the entities in your screenshot are grouped.



#8 teh_saccade

teh_saccade

    Advanced Member

  • Member
  • PipPipPip
  • 630 posts

Posted 18 December 2017 - 09:28 PM

I originally made that prefab, and to be honest we need a batter 'mirror' material.

Did you not see the mirrors and reflections in Vanished One's "In the Black"..?
They were great - especially the puddles of water.

 

// also the rotation origin bug in dr24 appears to have been fixed in dr25


Edited by teh_saccade, 18 December 2017 - 09:29 PM.


#9 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 19 December 2017 - 03:26 AM

Springheel - I broke that apart just to take the screen grab.

Perhaps someone can try importing that prefab (the existing mirror and stand) and see if it does the same. Id be interested if someone running a beta of 2.5.0 DR has a different outcome.

Cheers

#10 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19843 posts

Posted 19 December 2017 - 05:26 AM

drop me a pm to remind me to do it when i get home.

@TS, i havent played that mission yet so will have a look.

#11 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPipPip
  • 5560 posts

Posted 20 December 2017 - 08:41 AM

There are several buttons at the top that handle the rotate behaviour of entities.


FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#12 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 20 December 2017 - 10:20 AM

There are several buttons at the top that handle the rotate behaviour of entities.

 

Sadly none of those remedy this issue.

It is present in the existing prefab furniture>misc>mirror_stand.

 

Can anyone link DR 2.5.0 beta for me to try?

thanks



#13 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19843 posts

Posted 20 December 2017 - 03:30 PM

Its in the DR section of the forum fella -

 

http://forums.thedar...-release-tests/



#14 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 37101 posts

Posted 20 December 2017 - 04:44 PM

Springheel - I broke that apart just to take the screen grab.

Perhaps someone can try importing that prefab (the existing mirror and stand) and see if it does the same. Id be interested if someone running a beta of 2.5.0 DR has a different outcome.

Cheers

 

I imported it in 2.04 and it rotated fine for me.

 

Wait, I reread your original post...did you say you resized the models in your prefab?  Resizing models can produce some glitchy results.



#15 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 20 December 2017 - 05:36 PM

 

I imported it in 2.04 and it rotated fine for me.

 

Wait, I reread your original post...did you say you resized the models in your prefab?  Resizing models can produce some glitchy results.

 

I did scale the mirror (tea tray) part. But the others i reverted to worldspawn, changed dimensions then changed back to func_statics and re-applied the parameters.

 

It's strange that Bikerdudes original prefab doesn't work for me?!

 

I'll install the DR 2.5.0 pre2 release tonight and retry.

 

Thanks for helping out guys - getting there !

 

BTW - here are the prefabs for anyone to try -- https://drive.google...Mi3?usp=sharing


Edited by letran, 20 December 2017 - 05:38 PM.


#16 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 20 December 2017 - 06:45 PM

I've tried with DR 2.5.0 pre2 and it makes no difference.

 

Here's a quick video of the issue.

https://drive.google...iew?usp=sharing



#17 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPipPip
  • 5560 posts

Posted 21 December 2017 - 06:48 AM

You do not necessarely have to revert func_statics to worldspawn if you want to make changes. You can use tab to alternate through the primitives.


FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#18 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 21 December 2017 - 07:19 AM

You do not necessarely have to revert func_statics to worldspawn if you want to make changes. You can use tab to alternate through the primitives.

 

Thank you - yes i have discovered this but i sometimes forget !



#19 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19843 posts

Posted 21 December 2017 - 08:30 AM

Here's a quick video of the issue.

https://drive.google...iew?usp=sharing

I dont see what the issue is, yes the model has its origin angle different to the brush based FS - but they were all rotating together in the video..?


Edited by Bikerdude, 21 December 2017 - 08:31 AM.


#20 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 37101 posts

Posted 21 December 2017 - 08:50 AM

I don't see the problem in your video either.  The entire prefab seems to be rotating together, as expected.



#21 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 21 December 2017 - 09:39 AM

I don't see the problem in your video either.  The entire prefab seems to be rotating together, as expected.

 

That's true - the model looks OK. But the tilt angle of the mirror isn't then perpendicular with the rest of the frame. I'll see if i can capture in game.



#22 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 21 December 2017 - 09:54 AM

I'm afraid i'll need to find some free screen recording software. In the meantime i've done two screengrabs which attempt to show the issue. Not too clear though i'm afraid.

If anyone could recommend some open source screen recording software for windows i'd appreciate it.

 

thanks.

Attached Files



#23 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 37101 posts

Posted 21 December 2017 - 09:56 AM

https://screencast-o...screen_recorder is a good free one.



#24 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 21 December 2017 - 11:17 AM

Super thanks - Ill try that.

#25 letran

letran

    Member

  • Member
  • PipPip
  • 37 posts

Posted 21 December 2017 - 03:16 PM

OK i've captured a change in DR and how it turns out in game. One asset is imported as is, the other is rotated 45 degs or so.

 

https://drive.google...iew?usp=sharing

 

I'm not sure if i'm missing something here if others aren't getting that?

 

thanks again.







Also tagged with one or more of these keywords: origin, rotate, rotation, func_static, prefab, build

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users