Geometry Problems while unpacking
#1
Posted 20 November 2010 - 08:18 AM
I'm making a mod that converts rotwk into bfme1.
So far it is mostly successful, and have already tested it in private multiplayer matches.
A big problem that exists in bfme2/rotwk is that there are geometry issues when you unpack a base. Unless you have a small geometry or something, the object being unpacked will not show up if there are units or other objects obstructing the way.
Posts regarding this issue have been scattered around the forum and I wanted to start a new thread here to see how we can 'automatically' solve the unpacking issue. I look forward to ideas being posted so that we all can resolve this issue.
The following is a list of ways currently known to resolve the issue. There are advantages and disadvantages to each method.
1. Make geometries small (set all the geometries of the building you want to unpack to 1.0 or something). I do something like this in my mod, but for some reason dwarves in particular sometimes have a problem unpacking (for the economyplots). Maybe it is because their model is physically bigger than the other farms. Also, whenever unpacking anything and you have units there, those objects to be unpacked (such as a gate if you are in the gateway) disappear. The advantage of this method is that it allows for a 'drag and drop' of bfme1 style maps into bfme2/rotwk. I got it working for the most part, but sometimes you get a random glitch I mentioned above with the dwarves or gate or something. I want to however get rid of the issue completely if possible
2. Unpacking via scripts. This is what is done in all the other mods that convert bfme2 into bfme1. This does not require you change geometry and allows unpacking of bases without any problem. The disadvantage of this is that currently (as done in current mods), you have to manually add the scripts to every map you want to unpack. Also you have to wait a few seconds at the start of the map for the unpack to happen. A third potential problem is that, as I understand it, current mods that implement this method only unpack via scripts at the start of the match. Later in the match, when you unpack, it is done using the traditional unpacking.
What I want to do is to do is
1. find out how/why the unpack via script makes it work correctly and
2. Try to get it to unpack the same way (or better) in the mod code somewhere (as opposed to in every map) so that it does so automatically.
Any help in these areas is greatly appreciated.
#2
Posted 20 November 2010 - 11:51 AM
https://www.twitch.tv/vileartist - Yes shameless self-promotion
----------------------------------------------------------------------------------------------------------------------
"Old modders never die, they just fade away" ~ Hostile
#3
Posted 20 November 2010 - 01:49 PM
GameData BlockedByWallLeeway = 50 SecondsBeforeBaseCheckActive = 3 ClampedLOSHeightForCastleStructures = 100 End
Edited by DeeZire, 20 November 2010 - 01:50 PM.
#4
Posted 20 November 2010 - 01:55 PM
https://www.twitch.tv/vileartist - Yes shameless self-promotion
----------------------------------------------------------------------------------------------------------------------
"Old modders never die, they just fade away" ~ Hostile
#5
Posted 22 November 2010 - 07:17 AM
Doesn't seem to get rid of the problem.
#6
Posted 28 November 2010 - 12:25 AM
2. Try to get it to unpack the same way (or better) in the mod code somewhere (as opposed to in every map) so that it does so automatically.
I tried many approches to this problem ..
As you rightly posted its a 100% geometry problem with the
objects in the GondorBuildings.ini
The only viable solution that is 100% coding is using the delay geometry method
( which is not even my Idea ) saw it posted in the forum ..
;;;; All the oher codes ABOVE
Behavior = GrantUpgradeCreate MakeTheGeom1
UpgradeToGrant = Upgrade_DamrodRallyRangers
End
Behavior = ObjectCreationUpgrade MakeTheGeom2
TriggeredBy = Upgrade_DamrodRallyRangers
Delay = 10
GrantUpgrade = Upgrade_SwitchToRockThrowing
End
Behavior = GeometryUpgrade ModueTag_TowerGeom
TriggeredBy = Upgrade_SwitchToRockThrowing
ShowGeometry = Geom_Orig1 Geom_Orig2 ; Geom_Orig3 Bookend1 Bookend2 ; For more names !
HideGeometry = DummyGeom
End
Geometry = BOX
GeometryMajorRadius = 1.0
GeometryMinorRadius = 1.0
GeometryHeight = 1.0
GeometryName = DummyGeom
GeometryActive = Yes
Geometry = BOX
GeometryMajorRadius = 24.0
GeometryMinorRadius = 55.0
GeometryHeight = 52.0
GeometryOffset = X:-3 Y:55 Z:0
GeometryName = Geom_Orig1
GeometryActive = No
AdditionalGeometry = CYLINDER
GeometryMajorRadius = 33.0
GeometryMinorRadius = 0
GeometryHeight = 52.0
GeometryOffset = X:-12 Y:105 Z:0
GeometryName = Geom_Orig2
GeometryActive = No
GeometryRotationAnchorOffset = X:375.0 Y:0
GeometryIsSmall = No
GeometryContactPoint = X:35 Y: 25 Z:0 Grab
GeometryContactPoint = X:21 Y: 25 Z:0
GeometryContactPoint = X:21 Y: 60 Z:52
GeometryContactPoint = X:21 Y: 95 Z:0
GeometryContactPoint = X:31 Y: 95 Z:0 Grab
GeometryContactPoint = X:-50 Y: 95 Z:0 Grab
GeometryContactPoint = X:-30 Y: 95 Z:0
GeometryContactPoint = X:-21 Y: 60 Z:52
GeometryContactPoint = X:-21 Y: 25 Z:0
GeometryContactPoint = X:-40 Y: 25 Z:0 Grab
Shadow = SHADOW_VOLUME
End
The original geometry starts Hidden and is Active after the base unpacks correctly
The Delay time can be 1 and it still works
I have tested it and it works ..
I only had to painstaking re-create each NE / NW / SE / SW castle BASES files exactly
don't know why but this plus the new geometry codes will give a proper unpack
The build priority of the 'problem pieces ' had to be set to 90 I think in phase 1