playMaker

Author Topic: The Garbage Collection of Physics2D of bullets?  (Read 950 times)

brucezhu2018

  • Playmaker Newbie
  • *
  • Posts: 6
    • View Profile
The Garbage Collection of Physics2D of bullets?
« on: January 14, 2017, 09:32:56 AM »
Hi, everybody,I am a newbie of playmaker, I am just working on a shooting game made with playmaker. But I find my game is always lag from time to time, so I used the unity profiler to check the issue(on editor mode,for on my android device I can not get the object name instead by N/A), then I found the lag spike is caused mainly by the Garbage Collection, then I found the two lagest amount of GC Alloc when game is running, but I can not figer out the reasons.
You can refer to the screenshots below.
I use the unity3d 5.5f3  and playmaker1.8.3.
The first one of the Physics2d which I used to the bullet detect with trigger2d event, if the bullet hit the enemy, then I send events to other fsms for despawning the bullet and spawn hit effect and floating text(I use the Core Game Kit pool boss).
As the second screenshot shown, the Destroy->  AttributeHelperEngine.GetRequiredComponents  I don't know where it come from.
Could you please give me some hints about them? Thanks!
« Last Edit: January 14, 2017, 07:33:55 PM by brucezhu2018 »

brucezhu2018

  • Playmaker Newbie
  • *
  • Posts: 6
    • View Profile
Re: The Garbage Collection of Physics2D of bullets?
« Reply #1 on: January 14, 2017, 07:28:53 PM »
If anybody can help I will be appreciated!:-)

brucezhu2018

  • Playmaker Newbie
  • *
  • Posts: 6
    • View Profile
Re: The Garbage Collection of Physics2D of bullets?
« Reply #2 on: January 17, 2017, 10:40:38 PM »
Anybody  can help?Thanks!

krmko

  • Beta Group
  • Hero Member
  • *
  • Posts: 778
    • View Profile
    • Fat Pug Studio
Re: The Garbage Collection of Physics2D of bullets?
« Reply #3 on: January 18, 2017, 12:47:07 AM »
What is the question actually?

There has been talk of this while ago: http://hutonggames.com/playmakerforum/index.php?topic=4863.0