x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

Add Instance resets wind movement on all old instances

I have a HISMC (Hierarchical Instanced Static Mesh Component) and there are some speedtree trees inside. I have a WindDirectionalSource in the level so the trees leaves are moving with the wind.

But every time I add a new tree to the HISMC, the wind movement get's reset to 0 on all instances which are already inside of the HISMC. This is how it looks with one new tree per second:

alt text

(The gif is ~5 seconds long, so the reset each second is not because if the gif loop)

Product Version: Not Selected
Tags:
more ▼

asked Apr 29 '15 at 09:10 PM in Bug Reports

avatar image

John Alcatraz
1.3k 58 139 127

avatar image John Alcatraz Apr 30 '15 at 02:28 AM

After 5 hours of trying out any possible setting I found what exactly is the problem.

At first I thought I made something wrong, because the bug did not occur in a new project. But the important thing is, the HISMC needs to get spawned from an Actor while the game runs! A HISMC which is created manually with "Add Component" does work. But if you create the HISMC with the "Add HISMC" Node at Event Begin Play (or at any other place while the game runs), this bug appears.

So the "real component" works, while the component which is just a variable is buggy.

avatar image John Alcatraz Apr 30 '15 at 02:33 AM
(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hey John Alcatraz,

I saw on the forums you managed to find where the error is occurring and wanted to add a bit of my own findings in case it helps. It is my understanding that what you are trying to do is constantly check whether or not a tree has been 'cut' down as well as if a tree can 'grow' in a given area. Based upon those returns you will spawn any given number of trees that are available to grow in that area.

I noticed the 'Set Timer' is what is causing your mesh to reset based on the 'Time' input you enter. As soon as I removed this node and/or added a 'Clear Timer' node the issue went away. Perhaps creating a different system of checks and balances instead of calling the 'Update Instance Transform' of your 'Grow Tree' function every second. It dawned on me that a good way to show the growing process would be through a 'Timeline'. You did mention this was a bit buggy as a variable, so I am going to continue to play around with the project you sent to see if I can get it to update without resetting.

Cheers,

Andrew Hurley

more ▼

answered Apr 30 '15 at 07:44 PM

avatar image John Alcatraz Apr 30 '15 at 07:49 PM

I think you are mixing stuff. In this repro project I am not checking anything regarding being cut down or anything like this. I am just updating the scale of an instance every second.

Of course if you remove the Timer which is updating the transforms the bug goes away, because then no instances are updated :P

As I said it works with a real HISMC, so my own code (I call blueprints code...) regarding the growing and so on is not the issue. Real Component works, while dynamically created component does not work. You get what I mean?

avatar image AndrewHurley Apr 30 '15 at 09:26 PM

Hey John,

Yes, I do realize that what I was talking about was not involved in the example project you provided. I was trying to grasp the scope in which you were going to apply this blueprint because there are usually a few different ways to go about doing the same thing when it comes to game design in general. Either way, I do understand what you mean by generating these trees at runtime versus manually placing the component.

avatar image John Alcatraz Apr 30 '15 at 09:32 PM

The easiest workaround for me at the moment is just to use manually created components, so I don't need any other way to do the same thing. Anyway, thanks for looking into this! Have you entered a bug report for this with a number like UE-XXXXX?

avatar image John Alcatraz May 01 '15 at 01:53 AM

I just thought about that you said "It dawned on me that a good way to show the growing process would be through a 'Timeline'". The problem with a timeline is that it's wasting a lot of performance. I don't need my Trees to grow "smoothly" but once every 1 or 2 seconds is enough since they are growing reaaally slow. As long as it's not possible to set the "tick frequency" of a timeline using it would not make sense for me.

avatar image AndrewHurley May 02 '15 at 06:09 PM

Hey John,

There is actually already a bug entered for the 'Wind Directional Source' not functioning correctly with blueprints. Whether it is being called on directly or the scene is updated through a different source like the 'Update HISMC' with the 'Set Timer' node you have in place.

The bug is UE-3309, and I answered a question for another user who was experiencing issues with the 'Wind Directional Source' which you might find helpful as a temporary workaround. Although it does not address your issue directly, you can adapt the blueprint set up I have for your own project so the wind does not update incorrectly.

Wind Dynamic Update Broken

https://answers.unrealengine.com/questions/215244/bug476-wind-dynamic-update-broken.html

Regards,

Andrew H

avatar image John Alcatraz May 02 '15 at 06:25 PM

Thanks, but I don't think this is the bug I am experiencing. I am not updating wind directional source strength or speed in runtime.

The bug here is that a dynamically spawned HISMC is buggy. This is not the fault of the wind, it's the fault of the HISMC since it works fine if I manually create the HISMC. It might be connected to the other bug, but why are normal meshes and normal actors and manually created HISMCs working fine and only the dynamically one not working?

avatar image AndrewHurley May 04 '15 at 02:56 PM

If you simply remove the 'Wind Directional Source' from the scene the issue is not apparent so there is definitely a correlation here between the updating of your mesh and the communication or, lack there of, between the 'HISMC' and the 'Wind Directional Source.' You mentioned it works fine as the component alone, so would you mind showing me how you are doing this so I can check this set up as well?

Thank you,

Andrew Hurley

avatar image John Alcatraz May 04 '15 at 11:18 PM

After removing the wind directional source there is no wind at all in the scene so of course you can't see that the wind get's reset every second.

Instead of using the Add HISMC Node at Event Begin Play just remove the Node, go to the components tab and click on "Add Component" and select the HISMC. Then directly reference the HISMC in the blueprint instead of using the reference from the "Add HISMC" Node.

avatar image John Alcatraz May 06 '15 at 03:42 AM

Were you able to get it working with a manually created component?

avatar image AndrewHurley May 06 '15 at 03:23 PM

I did manage to get the manual HISMC set up working as you mentioned. I have entered a bug for this issue UE-15049 and will also make a note of it possibly being related to the communication of the Wind Directional Source Component communication within blueprints.

Cheers,

Andrew Hurley

avatar image John Alcatraz Jun 23 '15 at 03:45 AM

Hey Andrew, are there any updates on this? At the moment I still use the workaround to manually add the HISMCs as a component instead of spawning them dynamically, but I really would like to get rid of this workaround.

avatar image AndrewHurley Jun 23 '15 at 08:04 PM

No updates to the issue currently.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question