 |
Forum Info
|
 |
Forum Members: 18,581
Total Threads: 8,668
Posts: 94,539
Administrators:
DeeZire, Redemption
There are currently 45 users online.
|
 |
Partner Links
|
 |
 |
Advertisements
|
 |
|
| Generals & Zero Hour Editing Discuss any modding related issues to do with Generals and Zero Hour here. |
01-18-2006, 05:19 PM
|
#31 (permalink)
|
|
Senior Member
Join Date: May 2003
Location: Eindhoven, Netherlands
Posts: 2,278
|
I don't see why not. A building is an object like any other, so what's stopping you from using it as a transport?
|
|
|
01-18-2006, 05:34 PM
|
#32 (permalink)
|
|
Senior Member
Join Date: Jun 2003
Location: Germany
Posts: 363
|
I had exactly the same idea like Thinimus had with the "upgradable" walls in addition with the possibility of build gates. but the only thing that stopped me is that spawned objects - without or even with the overlord contain logic - ignore the terrain. so it can be that a wall is built on a very hilly terrain or even in water when the hub piece is near to a lake or river. that's the big big disadavantage with spawn logic...
but why should pathfinding be a problem for the AI? if the walls are defined as STRUCTUREs the units wander around it like they do with any other structure or am I wrong? :tard:
So, and since we're already talking about walls, what about gates that open / close automatically like they did in Tiberian Sun?
|
|
|
01-18-2006, 05:53 PM
|
#33 (permalink)
|
|
Senior Member
Join Date: Apr 2005
Location: Gamers Heaven
Posts: 781
|
you might be right Ambershee... but then again it is a bone right? It may work i have no clue... worth the try
|
|
|
01-18-2006, 07:30 PM
|
#34 (permalink)
|
|
Senior Member
Join Date: Dec 2003
Posts: 217
|
Quote:
Originally Posted by Dibelius";p="
I had exactly the same idea like Thinimus had with the "upgradable" walls in addition with the possibility of build gates. but the only thing that stopped me is that spawned objects - without or even with the overlord contain logic - ignore the terrain. so it can be that a wall is built on a very hilly terrain or even in water when the hub piece is near to a lake or river. that's the big big disadavantage with spawn logic...
but why should pathfinding be a problem for the AI? if the walls are defined as STRUCTUREs the units wander around it like they do with any other structure or am I wrong? :tard:
|
Well, yes, that's what will happen. But, the pathfinding engine in Generals is inefficient enough; adding more obstacles (especially ones which block off paths, AKA walls) is going to lag it even more. Ever tried playing on Twilight Flame with it's tiny choke points with 7 other AIs?
|
|
|
04-02-2008, 05:42 PM
|
#35 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
By the way, the american wall has animations that are not used in the EA games implementation (except for the reallydamaged conditionstate). The animations make the laser beams look like they are beaming.
One way to do straight walls is to make each wall segment have an ObjectCreationUpgrade (with ProductionUpdate of course, needed for object level upgrades) which OCLs the next wall segment at an appropriate offset distance in front of it (Disposition = LIKE_EXISTING so it faces the right way, with Offset = X:[length of wall segment] y:0 z:0).
You then get the dozer to build the first segment, and then select that segment and click a button to buy the upgrade that causes the OCLing of the next segment, and then select that segment and buy the upgrade that causes the OCLing of the next segment, and so on.
The wall object should have a UpgradeDie module to free the upgrade in the previous segment, so if a wall segment is killed, you can rebuild it from the previous segment by re-buying the upgrade.
In order to create a temporary gap in the wall (say for your own units to move through) you should give the wall object a suicide weapon and an AIUpdate module and a button to suicide it. You could just use a sell button to sell it but then if you sell it it does not free the upgrade since it does not die, and you cannot then close up the gap by re-buying the upgrade from the previous existing segment.
Another way to fire a suicide weapon if you don't want to add an AIUpdate module (which may be good for saving CPU time, i suspect AImodules may consume more resources than some others) is to use another ObjectCreationUpgrade module which calls an OCL which fires a suicide weapon, in the manner of the OCLs that fire the Nuke silo's nuke missile weapon. You then don't even need the WeaponSet.
You can arrange for the OCLs to also add hubs at the end of each wall segment, but a better way is to do away with separate hub objects altogether by either having no hubs, or having the hubs as part of the wall segment model, because using UpgradeDie gets tricky when you OCL more than one thing, since if you OCL a wall segment and a hub and both have UpgradeDie, and then one of those two things gets destroyed, then you can re-buy the upgrade to patch up the gap in the wall and the OCL will make 2 things again instead of just replacing the one destroyed thing, and one of them will be on top of the non-destroyed previous thing, which won't look nice and makes the wall of uneven strength.
The GLA wall is fine without hubs. The China wall is also ok without hubs. But the America wall doesn't look right since the lasers need a hub at the end to terminate them. Therefore i suggest editing the W3D model for the American wall to add the hubs on each end, or using the unused wall model ABSECUWALL which has built in hubs and one laser only.
regarding the China wall, since it's segments are smaller than the American and GLA walls, they should be cheaper and faster to upgrade to extend the wall.
Note: for the above method using ObjectCreationUpgrade to extend walls in a straight line, you should not have LINEBUILD in the KindOf, else it does not deduct from your money to build, and you should reiatin DEFENSIVE_WALL to make vehicles not drive through it.
Last edited by beng; 04-02-2008 at 05:49 PM.
|
|
|
04-02-2008, 06:00 PM
|
#36 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
I meant retain DEFENSIVE_WALL
|
|
|
04-02-2008, 06:16 PM
|
#37 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
Regarding the problem of OCLing more than one thing (a wall segemnt and a hub say, or maybe several wall segments and then a hub for China's wall) one way to work around it is to have the OCL give each thing a short invulnerabletime and have each thing fire a small radius weapon that affects ALLIES only, to destroy any previous wall or wall segment that it may land on. This would be similar to how hazard fields fire the hazard core weapon to prevent stacking of hazard fields.
|
|
|
04-02-2008, 06:40 PM
|
#38 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
Quote:
Originally Posted by Dibelius
I had exactly the same idea like Thinimus had with the "upgradable" walls in addition with the possibility of build gates. but the only thing that stopped me is that spawned objects - without or even with the overlord contain logic - ignore the terrain. so it can be that a wall is built on a very hilly terrain or even in water when the hub piece is near to a lake or river. that's the big big disadavantage with spawn logic...
but why should pathfinding be a problem for the AI? if the walls are defined as STRUCTUREs the units wander around it like they do with any other structure or am I wrong? :tard:
So, and since we're already talking about walls, what about gates that open / close automatically like they did in Tiberian Sun?
|
I have not tried it with walls, but you could try having the OCL specify:
DiesOnBadLand = Yes
Like for the rebel ambush, where rebels that spawn on water or slope will die, or maybe make the wall parachutable and put it in a parachute, since whatever is in a parachute always dies on slopes or water.
As for the gates, there is a gate like object that does seem to open or close to let only your own team through, it is the object AmericaCheckpoint in FactionBuilding.ini
Last edited by beng; 04-02-2008 at 06:46 PM.
|
|
|
04-03-2008, 08:36 AM
|
#39 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
Quote:
Originally Posted by beng
Another way to fire a suicide weapon if you don't want to add an AIUpdate module (which may be good for saving CPU time, i suspect AImodules may consume more resources than some others) is to use another ObjectCreationUpgrade module which calls an OCL which fires a suicide weapon, in the manner of the OCLs that fire the Nuke silo's nuke missile weapon. You then don't even need the WeaponSet.
|
I just tried it and it doesn't work. To fire a weapon from OCL you need to use OCLSpecialPower, not ObjectCreationUpgrade.
|
|
|
04-04-2008, 12:30 PM
|
#40 (permalink)
|
|
Senior Member
Join Date: Jan 2008
Posts: 325
|
There are different methods. To make it spawn only 1 object, you can use SpawnBehavior, like for stinger sites spawning stinger soldiers. You can make it spawn the spawned thing again if the thing is destroyed, or not (like tunnel networks which don't). You also need DefaultProductionExitUpdate, the module that is commented out in the tunnel network, to tell it the XYZ coordinates of where to spawn. For the America wall hub, you should tell it to spawn the AmericaWall at x:11.8 y:0 z:0
If you want to spawn more than 1 object than use the method i describe in post #38 above, using ObjectCreationUpgrade to OCL the wall segments. To OCL 3 wall segments for example:
Code:
ObjectCreationList OCL_AmericaWallForward3
CreateObject
ObjectNames = AmericaWall
Count = 1
Disposition = LIKE_EXISTING
Offset = X:11.8 Y:0.0 Z:0.0
DiesOnBadLand = Yes
End
CreateObject
ObjectNames = AmericaWall
Count = 1
Disposition = LIKE_EXISTING
Offset = X:31.8 Y:0.0 Z:0.0
DiesOnBadLand = Yes
End
CreateObject
ObjectNames = AmericaWall
Count = 1
Disposition = LIKE_EXISTING
Offset = X:51.8 Y:0.0 Z:0.0
DiesOnBadLand = Yes
End
CreateObject
ObjectNames = AmericaWallHub
Count = 1
Disposition = LIKE_EXISTING
Offset = X:63.6 Y:0.0 Z:0.0
DiesOnBadLand = Yes
End
End
The tricky thing with multiple objects is how to replace individual wall segments without putting extra ones on existing walls. I am still working on that problem and it is looking like either using the hazard core weapon method that prevents stacking of hazard fields, or making a new hub model with Station bones so it can work like a firebase and the wall segments can be contained inside it, so when you OCL a bunch of new ones, only the empty stations get filled. As i am doing a map.ini for walls and not a full mod, i think i will have to go with the hazard core method rather than making new W3D models.
Last edited by beng; 04-04-2008 at 12:38 PM.
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -4. The time now is 03:26 PM.
|