Hey guys, I really am happy with the toolset and I'm excited to get started on my own mod but I'm a little disappointed in the lack of documentation for various little things. It'd be nice if there was a wiki that we could all contribute toward but I guess that's a fantasy.
I've got my test tuning pack and wincondition working but a few things I'm wondering about first, how do I edit start units and buildings?
My objective is to make a mod that will keep gameplay as-is for the computer but disable/change things for the player. Currently my mod is the basic win/scar file except I changed MaxPopulation can anyone help me out further?
Winconditions assistance for Lua modder
26 Dec 2014, 11:43 AM
#1
Posts: 1
29 Dec 2014, 00:48 AM
#2
Posts: 139
Win condition files and tuning packs both allow substituting starting buildings/units for factions (the latter with an ugly hack), but I don't know of a way for doing it only for human players.
However, your win condition's script can do it by iterating over the players to detect which are humans, and for those it can use conditionals to detect which factions they are, then just delete the default starting unit for that faction and spawn the new one(s) you want them to have.
Buildings may be more challenging. For base bunkers you can probably use the script to collect all the entities of the relevant type, iterate over that list, and for each one find the location and orientation, destroy it, and spawn what you want using the same location and orientation.
But I don't think that would work for the HQ building.
However, your win condition's script can do it by iterating over the players to detect which are humans, and for those it can use conditionals to detect which factions they are, then just delete the default starting unit for that faction and spawn the new one(s) you want them to have.
Buildings may be more challenging. For base bunkers you can probably use the script to collect all the entities of the relevant type, iterate over that list, and for each one find the location and orientation, destroy it, and spawn what you want using the same location and orientation.
But I don't think that would work for the HQ building.
PAGES (1)
2 users are browsing this thread:
2 guests
Livestreams
60 | |||||
11 | |||||
6 | |||||
6 | |||||
0 | |||||
141 | |||||
25 | |||||
21 | |||||
8 | |||||
5 |
Ladders Top 10
-
#Steam AliasWL%Streak
- 1.831222.789+37
- 2.600215.736+15
- 3.34957.860+14
- 4.1107614.643+8
- 5.305114.728+1
- 6.916405.693-2
- 7.273108.717+24
- 8.722440.621+4
- 9.1041674.607-2
- 10.17146.788+1
Replay highlight
VS
- cblanco ★
- 보드카 중대
- VonManteuffel
- Heartless Jäger
Einhoven Country
Honor it
9
Download
1235
Board Info
942 users are online:
942 guests
0 post in the last 24h
8 posts in the last week
34 posts in the last month
8 posts in the last week
34 posts in the last month
Registered members: 49107
Welcome our newest member, Falac851
Most online: 2043 users on 29 Oct 2023, 01:04 AM
Welcome our newest member, Falac851
Most online: 2043 users on 29 Oct 2023, 01:04 AM