Unable to delete a body

Report problems here (or use the built-in feedback dialog in the editor)
Post Reply
FizzyChicken
Posts: 7
Joined: Wed Jan 23, 2013 10:14 pm

Unable to delete a body

Post by FizzyChicken » Thu May 09, 2013 10:03 am

Hi - I have a scene where I can't delete a certain body (which has not fixtures). Other bodies I can delete fine, but not this one. I also can't delete any joints attached to the body. There's not feedback at all when I hit 'Delete' either.

Please find attached the scene - the joint in question is called 'todelete'

Cheers


------


{
"collisionbitplanes" :
{
"names" :
[
"env",
"wheels",
"limbs1",
"body",
"limbs2",
"bitplane6",
"bitplane7",
"bitplane8",
"bitplane9",
"bitplane10",
"bitplane11",
"bitplane12",
"bitplane13",
"bitplane14",
"bitplane15",
"bitplane16",
"bitplane17",
"bitplane18",
"bitplane19",
"bitplane20",
"bitplane21",
"bitplane22",
"bitplane23",
"bitplane24",
"bitplane25",
"bitplane26",
"bitplane27",
"bitplane28",
"bitplane29",
"bitplane30",
"bitplane31",
"bitplane32"
]
},
"metaworld" :
{
"allowSleep" : true,
"autoClearForces" : true,
"continuousPhysics" : true,
"exportOptions" :
{
"saveFullPathForImages" : false,
"useHumanReadableFloats" : true
},
"gravity" :
{
"x" : 0,
"y" : -10.0
},
"metabody" :
[

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"id" : 1,
"linearVelocity" : 0,
"massData-mass" : 1,
"name" : "todelete",
"position" :
{
"x" : -1.239779976458522e-05,
"y" : 0.6823099851608276
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 16,
"filter-maskBits" : 65531,
"friction" : 0.2,
"id" : 2,
"name" : "f_upperleg2",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.1065500006079674,
0.1065500006079674,
0.1065500006079674,
-0.1065500006079674
],
"y" : [ -0.250, -0.250, 0.250, 0.250 ]
}
}
],
"id" : 2,
"linearVelocity" : 0,
"massData-I" : 0.002623009029775858,
"massData-mass" : 0.1065500006079674,
"name" : "upper leg2",
"position" :
{
"x" : 0.01486159954220057,
"y" : 0.6817420125007629
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 8,
"friction" : 0.2,
"id" : 3,
"name" : "f_head",
"shapes" :
[

{
"radius" : 0.1500000059604645,
"type" : "circle"
}
],
"vertices" :
{
"x" : [ 0.0 ],
"y" : [ 0.0 ]
}
}
],
"id" : 3,
"linearVelocity" : 0,
"massData-I" : 0.0007952157175168395,
"massData-mass" : 0.07068584114313126,
"name" : "head",
"position" :
{
"x" : 0.0006811618804931641,
"y" : 1.694250345230103
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"friction" : 0.2,
"id" : 4,
"name" : "f_ignore",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-4.692309379577637,
4.692309379577637,
4.692309379577637,
-4.692309379577637
],
"y" : [ -0.50, -0.50, 0.50, 0.50 ]
}
}
],
"id" : 4,
"linearVelocity" : 0,
"name" : "ignore",
"position" :
{
"x" : -0.01058912277221680,
"y" : -0.4645074009895325
},
"type" : "static"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 8,
"friction" : 0.2,
"id" : 5,
"name" : "f_body",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.1690544486045837,
0.1690544486045837,
0.1690544486045837,
-0.1690544486045837
],
"y" :
[
-0.3823531866073608,
-0.3823531866073608,
0.3823530673980713,
0.3823530673980713
]
}
}
],
"id" : 5,
"linearVelocity" : 0,
"massData-I" : 0.01506277918815613,
"massData-center" :
{
"x" : 0,
"y" : -5.960464477539062e-08
},
"massData-mass" : 0.2585539817810059,
"name" : "body",
"position" :
{
"x" : 0.007433414459228516,
"y" : 1.129065990447998
},
"type" : "dynamic"
},

{
"angle" : 0.5786085128784180,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65534,
"friction" : 0.2,
"id" : 6,
"name" : "f_upperarm1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.05076923966407776,
0.05076920986175537,
0.05076920986175537,
-0.05076923966407776
],
"y" :
[
-0.2447525262832642,
-0.2447525262832642,
0.2447524070739746,
0.2447524070739746
]
}
}
],
"id" : 6,
"linearVelocity" : 0,
"massData-I" : 0.001035181106999516,
"massData-center" :
{
"x" : -1.490116119384766e-08,
"y" : -5.960464477539062e-08
},
"massData-mass" : 0.04970357194542885,
"name" : "upper arm1",
"position" :
{
"x" : 0.1166408061981201,
"y" : 1.273021221160889
},
"type" : "dynamic"
},

{
"angle" : 1.337919712066650,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65526,
"friction" : 0.2,
"id" : 7,
"name" : "f_lowerarm1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.04178311303257942,
0.03718657419085503,
0.03948484733700752,
-0.03948483243584633
],
"y" :
[
-0.2384858429431915,
-0.2384858727455139,
0.1751865595579147,
0.1751865744590759
]
}
}
],
"id" : 7,
"linearVelocity" : 0,
"massData-I" : 0.0005156103870831430,
"massData-center" :
{
"x" : -0.001149133197031915,
"y" : -0.03164964169263840
},
"massData-mass" : 0.03266757726669312,
"name" : "lower arm1",
"position" :
{
"x" : 0.3474643230438232,
"y" : 1.086872577667236
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 16,
"friction" : 0.2,
"id" : 8,
"name" : "f_lowerleg2",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.08415830135345459,
0.08415839821100235,
0.08415839821100235,
-0.08415830135345459
],
"y" :
[
-0.2222220003604889,
-0.2222220003604889,
0.2222220003604889,
0.2222220003604889
]
}
}
],
"id" : 8,
"linearVelocity" : 0,
"massData-I" : 0.001408005016855896,
"massData-center" :
{
"x" : 4.842877388000488e-08,
"y" : 0
},
"massData-mass" : 0.07480734586715698,
"name" : "lower leg2",
"position" :
{
"x" : 0.02504160068929195,
"y" : 0.2796219885349274
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65519,
"friction" : 0.2,
"id" : 9,
"name" : "f_upperleg1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.1035715341567993,
0.1035715341567993,
0.1035715341567993,
-0.1035715341567993
],
"y" :
[
-0.2543860077857971,
-0.2543860077857971,
0.2543861269950867,
0.2543861269950867
]
}
}
],
"id" : 9,
"linearVelocity" : 0,
"massData-I" : 0.002650149166584015,
"massData-center" :
{
"x" : 0,
"y" : 5.960464477539062e-08
},
"massData-mass" : 0.1053886190056801,
"name" : "upper leg1",
"position" :
{
"x" : -1.239779976458522e-05,
"y" : 0.6823099851608276
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65519,
"friction" : 0.2,
"id" : 10,
"name" : "f_lowerleg1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.06681871414184570,
0.06681871414184570,
0.06681871414184570,
-0.06681871414184570
],
"y" :
[
-0.2175844907760620,
-0.2175844907760620,
0.2175845503807068,
0.2175845503807068
]
}
}
],
"id" : 10,
"linearVelocity" : 0,
"massData-I" : 0.001004291465505958,
"massData-center" :
{
"x" : 0,
"y" : 2.980232238769531e-08
},
"massData-mass" : 0.05815486982464790,
"name" : "lower leg1",
"position" :
{
"x" : -0.001690149307250977,
"y" : 0.2809461355209351
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65519,
"friction" : 0.2,
"id" : 11,
"name" : "f_foot1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.1475333571434021,
0.1475334167480469,
0.1475334167480469,
-0.1475333571434021
],
"y" :
[
-0.04015785455703735,
-0.04015785455703735,
0.04015803337097168,
0.04015803337097168
]
}
}
],
"id" : 11,
"linearVelocity" : 0,
"massData-I" : 0.0001846809464041144,
"massData-center" :
{
"x" : 2.980232238769531e-08,
"y" : 8.940696005765858e-08
},
"massData-mass" : 0.02369854971766472,
"name" : "foot1",
"position" :
{
"x" : 0.06118798255920410,
"y" : 0.09482675790786743
},
"type" : "dynamic"
},

{
"angle" : 0,
"angularVelocity" : 0,
"awake" : true,
"fixture" :
[

{
"density" : 1,
"filter-categoryBits" : 4,
"filter-maskBits" : 65518,
"friction" : 0.2,
"id" : 12,
"name" : "f_hand1",
"shapes" :
[

{
"type" : "polygon"
}
],
"vertices" :
{
"x" :
[
-0.09320533275604248,
0.09320557117462158,
0.09320557117462158,
-0.09320533275604248
],
"y" :
[
-0.03470325469970703,
-0.03470325469970703,
0.03470325469970703,
0.03470325469970703
]
}
}
],
"id" : 12,
"linearVelocity" : 0,
"massData-I" : 4.265947791282088e-05,
"massData-center" :
{
"x" : 1.192092895507812e-07,
"y" : 0
},
"massData-mass" : 0.01293812971562147,
"name" : "hand1",
"position" :
{
"x" : 0.6161202192306519,
"y" : 1.039127349853516
},
"type" : "dynamic"
}
],
"metajoint" :
[

{
"anchorA" :
{
"x" : -0.06558279693126678,
"y" : 0.005082369782030582
},
"anchorB" :
{
"x" : -0.002704619895666838,
"y" : -0.1810369938611984
},
"bodyA" : 11,
"bodyB" : 10,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 1,
"lowerLimit" : -0.8726646304130554,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "ankle",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 0.5235987901687622
},

{
"anchorA" :
{
"x" : -0.0005233290139585733,
"y" : -0.2188290059566498
},
"anchorB" :
{
"x" : 0.001154419966042042,
"y" : 0.1825339943170547
},
"bodyA" : 9,
"bodyB" : 10,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 2,
"lowerLimit" : -2.094395160675049,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "knee",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : -0.1745329201221466
},

{
"anchorA" :
{
"x" : -0.005887989886105061,
"y" : -0.2909820079803467
},
"anchorB" :
{
"x" : 0.001557830022647977,
"y" : 0.1557739973068237
},
"bodyA" : 5,
"bodyB" : 9,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 3,
"lowerLimit" : -0.7853981852531433,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "hip",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 2.094395160675049
},

{
"anchorA" :
{
"x" : -0.001678179949522018,
"y" : 0.1850630044937134
},
"anchorB" :
{
"x" : 0.006598710082471371,
"y" : 0.2979770004749298
},
"bodyA" : 6,
"bodyB" : 5,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 4,
"lowerLimit" : -2.792526721954346,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "shoulder",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 1.745329260826111
},

{
"anchorA" :
{
"x" : 0.01343860011547804,
"y" : -0.1951870024204254
},
"anchorB" :
{
"x" : 0.00323111005127430,
"y" : 0.1167289987206459
},
"bodyA" : 6,
"bodyB" : 7,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 5,
"lowerLimit" : 0.08726646006107330,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "elbow",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 2.094395160675049
},

{
"anchorA" :
{
"x" : -0.005887989886105061,
"y" : -0.2909820079803467
},
"anchorB" :
{
"x" : 0.001557830022647977,
"y" : 0.1557739973068237
},
"bodyA" : 5,
"bodyB" : 1,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 6,
"lowerLimit" : -0.7853981852531433,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "hip",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 2.094395160675049
},

{
"anchorA" :
{
"x" : -0.003297920105978847,
"y" : -0.1881240010261536
},
"anchorB" :
{
"x" : -0.01005019992589951,
"y" : 0.3770599961280823
},
"bodyA" : 3,
"bodyB" : 5,
"collideConnected" : false,
"dampingRatio" : 0,
"frequency" : 7.50,
"id" : 7,
"name" : "neck",
"referenceAngle" : 0,
"type" : "weld"
},

{
"anchorA" :
{
"x" : -0.004421799909323454,
"y" : -0.2063409984111786
},
"anchorB" :
{
"x" : -0.06956119835376740,
"y" : 0.002774782478809357
},
"bodyA" : 7,
"bodyB" : 12,
"collideConnected" : false,
"enableLimit" : false,
"enableMotor" : false,
"id" : 8,
"lowerLimit" : -0.3490658402442932,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "wrist",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 0.3490658402442932
},

{
"anchorA" :
{
"x" : -0.0005233290139585733,
"y" : -0.2188290059566498
},
"anchorB" :
{
"x" : 0.001154419966042042,
"y" : 0.1825339943170547
},
"bodyA" : 1,
"bodyB" : 10,
"collideConnected" : false,
"enableLimit" : true,
"enableMotor" : false,
"id" : 9,
"lowerLimit" : -2.094395160675049,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "knee",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : -0.1745329201221466
},

{
"anchorA" :
{
"x" : -0.01018050033599138,
"y" : 0.1679739952087402
},
"anchorB" :
{
"x" : -0.002752299886196852,
"y" : -0.2793489992618561
},
"bodyA" : 2,
"bodyB" : 5,
"collideConnected" : false,
"enableLimit" : false,
"enableMotor" : false,
"id" : 11,
"lowerLimit" : 0,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "joint0",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 0
},

{
"anchorA" :
{
"x" : -0.005090239923447371,
"y" : 0.1934249997138977
},
"anchorB" :
{
"x" : 0.005089759826660156,
"y" : -0.2086949944496155
},
"bodyA" : 8,
"bodyB" : 2,
"collideConnected" : false,
"enableLimit" : false,
"enableMotor" : false,
"id" : 12,
"lowerLimit" : 0,
"maxMotorTorque" : 0,
"motorSpeed" : 0,
"name" : "joint1",
"referenceAngle" : 0,
"type" : "revolute",
"upperLimit" : 0
}
],
"positionIterations" : 3,
"stepsPerSecond" : 60.0,
"subStepping" : false,
"velocityIterations" : 8,
"warmStarting" : true
}
}

iforce2d
Site Admin
Posts: 860
Joined: Sat Dec 22, 2012 7:20 pm

Re: Unable to delete a body

Post by iforce2d » Thu May 09, 2013 6:12 pm

You need to have the main scene area in focus for the keys to work. I found I can delete the body ok by selecting the body in the items panel (F6) and deleting it after giving the keyboard focus to the main window. If this doesn't make any difference, let me know which OS you are using.

Post Reply