Page 1 of 1

mod Supply Truck to transport infantry?

Posted: Tue May 25, 2021 6:06 am
by RedAlertMig
I tried modding my map to make the Supply Truck transport infantry like the APC instead of give money to allies. I set the cash to 0 but the game crashes. Here's what the change look like:



TRUK:
Inherits: ^Vehicle
Inherits@selection: ^SelectableSupportUnit
Buildable:
Queue: Vehicle
BuildPaletteOrder: 410
Prerequisites: ~techlevel.low
Description: Transports cash to other players.\n Unarmed
Valued:
Cost: 500
Tooltip:
Name: Supply Truck
Health:
HP: 11000
Armor:
Type: Light
Mobile:
Speed: 128
RevealsShroud:
Range: 4c0
Cargo:
Types: Infantry
MaxWeight: 5
PipCount: 5
LoadingCondition: notmobile
DeliversCash:
Payload: 0
PlayerExperience: 0
SpawnActorOnDeath:
Actor: moneycrate

Re: mod Supply Truck to transport infantry?

Posted: Wed May 26, 2021 12:28 am
by abcdefg30
I'd just remove the lines

Code: Select all

DeliversCash:
Payload: 0
PlayerExperience: 0
What does the crash log say?

Re: mod Supply Truck to transport infantry?

Posted: Wed May 26, 2021 7:07 am
by RedAlertMig
abcdefg30 wrote: Wed May 26, 2021 12:28 am I'd just remove the lines

Code: Select all

DeliversCash:
Payload: 0
PlayerExperience: 0
What does the crash log say?
removed those lines but still crashes:


OpenRA engine version release-20200503
Red Alert mod version release-20200503
Date: 2021-05-26 06:04:41Z
Operating System: Windows (Microsoft Windows NT 6.2.9200.0)
Runtime Version: .NET CLR 4.0.30319.42000
Exception of type `OpenRA.YamlException`: s-vehicles.yaml:52: Parent type `^Vehicle` not found
at OpenRA.MiniYaml.ResolveInherits(String key, MiniYaml node, Dictionary`2 tree, Dictionary`2 inherited)
at OpenRA.MiniYaml.Merge(IEnumerable`1 sources)
at OpenRA.Graphics.SequenceProvider.Load(IReadOnlyFileSystem fileSystem, MiniYaml additionalSequences)
at OpenRA.Graphics.SequenceProvider.<>c__DisplayClass7_0.<.ctor>b__0()
at System.Lazy`1.CreateValue()
at System.Lazy`1.LazyInitValue()
at OpenRA.Graphics.SequenceProvider.Preload()
at OpenRA.Map.PostInit()
at OpenRA.Map..ctor(ModData modData, IReadOnlyPackage package)
at OpenRA.ModData.PrepareMap(String uid)
at OpenRA.Game.StartGame(String mapUID, WorldType type)
at OpenRA.Network.UnitOrders.ProcessOrder(OrderManager orderManager, World world, Int32 clientId, Order order)
at OpenRA.Network.OrderManager.TickImmediate()
at OpenRA.Sync.<>c__DisplayClass13_0.<RunUnsynced>b__0()
at OpenRA.Game.InnerLogicTick(OrderManager orderManager)
at OpenRA.Game.LogicTick()
at OpenRA.Game.Loop()
at OpenRA.Game.Run()
at OpenRA.Game.InitializeAndRun(String[] args)
at OpenRA.WindowsLauncher.RunGame(String[] args)



UPDATE: i fixed the crash by removing

Inherits: ^Vehicle
Inherits@selection: ^SelectableSupportUnit


but i still cant load troops in the truck

Re: mod Supply Truck to transport infantry?

Posted: Wed May 26, 2021 11:56 am
by abcdefg30
Does your infantry have the Passenger trait with the correct CargoType?

Code: Select all

Passenger:
	CargoType: Infantry

Re: mod Supply Truck to transport infantry?

Posted: Thu May 27, 2021 5:48 am
by RedAlertMig
abcdefg30 wrote: Wed May 26, 2021 11:56 am Does your infantry have the Passenger trait with the correct CargoType?

Code: Select all

Passenger:
	CargoType: Infantry
It's the default infantry, they can enter APCs.

Re: mod Supply Truck to transport infantry?

Posted: Thu May 27, 2021 4:27 pm
by abcdefg30
Hm, the only other thing that could be is if you use spaces for indentation. (You have to use tabs.) So double check that. Otherwise I'm out of ideas. :(

Re: mod Supply Truck to transport infantry?

Posted: Fri May 28, 2021 8:30 pm
by RedAlertMig
abcdefg30 wrote: Thu May 27, 2021 4:27 pm Hm, the only other thing that could be is if you use spaces for indentation. (You have to use tabs.) So double check that. Otherwise I'm out of ideas. :(
I copy pasted the code so no space or tab needed. I think the supply cargo ability isnt allowing it but i dont know how to removed it from the map mod, if i dont add the cargo codes then its automatically added.

Re: mod Supply Truck to transport infantry?

Posted: Wed Jun 23, 2021 10:42 am
by Matthew63
Rheinmetall To Supply 382 Retrofit Kits For British Logistic Vehicles Fleet. During the period 2005 to 2013, the British Army procured more than However, the growing demand for transport solutions for containers has continued to rise.