Fehler beim Platzieren von Objekten behoben
This commit is contained in:
@@ -302,6 +302,8 @@ public class SharedInput {
|
||||
public volatile boolean objectSelectionChanged = false;
|
||||
/** Wird von JME3 gesetzt, wenn ein Objekt gerade neu platziert wurde (nicht nur selektiert). */
|
||||
public volatile boolean objectJustPlaced = false;
|
||||
/** JavaFX → JME3: Selektion sofort aufheben (z. B. nach Massenplatzierung). */
|
||||
public volatile boolean deselectAllRequest = false;
|
||||
/** Wird von JME3 gesetzt, wenn ein Objekt im Platzierungsmodus angeklickt wurde → JFX wechselt Panel zu Edit. */
|
||||
public volatile boolean objectClickedWhileInPlaceMode = false;
|
||||
|
||||
|
||||
@@ -416,6 +416,11 @@ public class SceneObjectState extends BaseAppState {
|
||||
|| input.activeLayer == SharedInput.LAYER_AUSWAHL;
|
||||
if (!isObjectLayer) return;
|
||||
|
||||
if (input.deselectAllRequest) {
|
||||
input.deselectAllRequest = false;
|
||||
deselectAll();
|
||||
}
|
||||
|
||||
if (input.deselectAllOnAuswahl) {
|
||||
input.deselectAllOnAuswahl = false;
|
||||
deselectAll();
|
||||
|
||||
@@ -87,6 +87,8 @@ public class ObjectController implements ToolController {
|
||||
ctx.input().objectJustPlaced = false;
|
||||
if (multiPlaceCB == null || !multiPlaceCB.isSelected()) {
|
||||
showEditPanel();
|
||||
} else {
|
||||
ctx.input().deselectAllRequest = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -112,6 +112,7 @@ public class WorldObjectsState extends BaseAppState {
|
||||
|
||||
// Baum-Stammkollision: Capsule statt Vollmesh (Blätter ausgeschlossen)
|
||||
String objPath = m.modelPath() != null ? m.modelPath() : "";
|
||||
boolean hasCustomCollision = objPath.startsWith("Models/trees/") || objPath.contains("/grapevine/");
|
||||
if (objPath.contains("/grapevine/") && bulletAppState != null) {
|
||||
try {
|
||||
s.updateGeometricState();
|
||||
@@ -149,8 +150,8 @@ public class WorldObjectsState extends BaseAppState {
|
||||
}
|
||||
}
|
||||
|
||||
// Physik-Kollision für solide Objekte
|
||||
if (m.solid() && bulletAppState != null) {
|
||||
// Physik-Kollision für solide Objekte (nicht für Bäume/Reben – die haben eigene Kollision oben)
|
||||
if (m.solid() && !hasCustomCollision && bulletAppState != null) {
|
||||
try {
|
||||
RigidBodyControl rbc = new RigidBodyControl(
|
||||
CollisionShapeFactory.createMeshShape(s), 0f);
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -15,3 +15,15 @@ Models/imported/feuerstelle1.j3o 1.46137 2.00000 -1.08840 0.00000 1.00000 0.0000
|
||||
Models/trees/palm/palm_20260914_195434.j3o 226.76038 1.25643 -893.77020 -1.59663 1.00000 -0.00000 0.00000 true true true 50.00000 150.00000 300.00000 PALM
|
||||
Models/trees/willow/willow_20260914_210538.j3o 256.04678 5.84959 -887.66675 0.00000 1.00000 0.00000 0.00000 true true true 50.00000 150.00000 300.00000 TREE
|
||||
Models/imported/kampfdummy.j3o -5.95449 2.00000 -11.12527 0.00000 1.00000 0.00000 0.00000 true true true 30.00000 80.00000 120.00000 DUMMY
|
||||
Models/trees/willow/willow_20260914_210538.j3o 150.00494 2.94445 -13.38018 0.82411 1.00000 0.00000 0.00000 true true true 30.00000 80.00000 200.00000 TREE
|
||||
Models/trees/willow/willow_20260914_210538.j3o 172.12804 2.96088 -11.39893 1.61566 1.00000 0.00000 0.00000 true true true 30.00000 80.00000 200.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190953.j3o 164.84961 7.14919 15.62826 -3.10077 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 NONE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190947.j3o 155.80219 9.33038 16.30900 2.93147 1.00000 0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190939.j3o 143.65674 12.30280 20.52005 0.66436 1.00000 0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190947.j3o 132.98308 15.19385 24.61456 -0.02996 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190953.j3o 130.20370 15.43188 16.47620 -0.60550 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 NONE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190947.j3o 140.65765 13.16088 14.08950 -0.38551 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190939.j3o 148.62924 10.59328 11.05173 -0.38486 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190953.j3o 153.52829 9.72414 9.98234 -2.23312 1.00000 -0.00000 0.00000 false true true 30.00000 80.00000 120.00000 NONE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190939.j3o 163.28604 7.18056 7.21066 2.85147 1.00000 0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
Models/trees/pine/medium/pine_medium_20260706_190947.j3o 170.87265 5.19999 5.21380 1.22752 1.00000 0.00000 0.00000 false true true 30.00000 80.00000 120.00000 TREE
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# polygon_points waterHeight flowDegrees speed waveScale waveAmplitude transparency waterR waterG waterB deepR deepG deepB
|
||||
155.13664,11.00000,-898.11578;120.48705,11.00000,-897.61938;107.05534,11.00000,-890.41797;96.71703,11.00000,-875.01575;98.34164,11.00000,-854.85681;182.64165,11.00000,-829.23749;195.95512,11.00000,-848.04095 11.00000 180.0 0.5000 0.008000 0.10000 0.15000 0.05000 0.25000 0.55000 0.02000 0.12000 0.30000
|
||||
219.67131,1.90000,-796.04559;197.17520,1.90000,-800.89313;192.60945,1.90000,-797.65149;190.13742,1.90000,-767.83209;221.88794,1.90000,-767.83209 1.90000 0.0 0.5000 0.008000 0.10000 0.15000 0.05000 0.25000 0.55000 0.02000 0.12000 0.30000
|
||||
145.45116,2.80000,4.87381;163.20361,2.80000,3.51198;172.70294,2.80000,2.84045;175.18158,2.80000,-1.35778;174.98405,2.80000,-7.36192;171.01855,2.80000,-12.93119;156.72575,2.80000,-17.72083;143.90723,2.80000,-10.86586 2.80000 0.0 0.5000 0.008000 0.10000 0.15000 0.10196 0.30196 0.10196 0.02000 0.12000 0.30000
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user