Page MenuHome

BGE : Fix for T43724 and T41599 addObject() with KX_FontObject and overlay scene
ClosedPublic

Authored by Porteries Tristan (panzergame) on Feb 19 2015, 3:23 PM.

Details

Summary

GetGameObjectType is overwritten in KX_FontObject to differentiate a font object into AddNodeReplicaObject function. Now, in this function, we add fonts in the appropriate list.

Diff Detail

Repository
rB Blender
Branch
ge_fix_fond_adding

Event Timeline

Porteries Tristan (panzergame) retitled this revision from to BGE : Fix T43724 addObject() with KX_FontObject and overlay scene.
Porteries Tristan (panzergame) updated this object.
Porteries Tristan (panzergame) retitled this revision from BGE : Fix T43724 addObject() with KX_FontObject and overlay scene to BGE : Fix T43724; T41599 addObject() with KX_FontObject and overlay scene.Feb 22 2015, 4:46 PM

Can you install arcanist and send the patch via 'arc diff'? Otherwise we can't see the context of the patch (i.e., to see more lines of the changed files before or after the changes)

source/gameengine/Ketsji/KX_Scene.h
143 ↗(On Diff #3588)

Fine by me, don't need to add those comments in the final patch though.

I still didn't understand what's the point of this patch. Does it change anything for the final user?

source/gameengine/Ketsji/KX_Scene.cpp
535

replace if by else if or even better, by a switch.

The patch just corrects crashes, because if we add font in overlay scene the font it's added in the scene which contains the logic controller, and yes it's change nothing for the final user.

The patch just corrects crashes, because if we add font in overlay scene the font it's added in the scene which contains the logic controller, and yes it's change nothing for the final user.

If it fixes a crash then it certainly helps the user ;) Do you have a sample file that reproduces the crash? Was it ever reported?

Example files are in the bug in the title : T43724 and T41599.

Jorge Bernal (lordloki) added inline comments.
source/gameengine/Ketsji/KX_FontObject.h
73

should be public?

set function GetGameObjectType() public, how that compiles and works before ?

Looks good to me.

Note: I checked both bugs and with these changes they are working now.

This revision is now accepted and ready to land.Feb 28 2015, 2:25 AM
Jorge Bernal (lordloki) retitled this revision from BGE : Fix T43724; T41599 addObject() with KX_FontObject and overlay scene to BGE : Fix for T43724 and T41599 addObject() with KX_FontObject and overlay scene.Mar 15 2015, 9:44 AM
Jorge Bernal (lordloki) updated this object.
Jorge Bernal (lordloki) edited edge metadata.
This revision was automatically updated to reflect the committed changes.