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)
0 user is browsing this thread:
Livestreams
63 | |||||
40 | |||||
39 | |||||
16 | |||||
9 | |||||
6 | |||||
1 | |||||
640 | |||||
12 | |||||
1 |
Ladders Top 10
-
#Steam AliasWL%Streak
- 1.653231.739+13
- 2.838223.790+1
- 3.35057.860+15
- 4.590233.717+6
- 5.278108.720+29
- 6.306114.729+2
- 7.645.928+5
- 8.922406.694+1
- 9.1118621.643-1
- 10.265138.658+2
Replay highlight
VS
- cblanco ★
- 보드카 중대
- VonManteuffel
- Heartless Jäger
Einhoven Country
Honor it
10
Download
1243
Board Info
577 users are online:
577 guests
0 post in the last 24h
2 posts in the last week
28 posts in the last month
2 posts in the last week
28 posts in the last month
Registered members: 49388
Welcome our newest member, KETTA
Most online: 2043 users on 29 Oct 2023, 01:04 AM
Welcome our newest member, KETTA
Most online: 2043 users on 29 Oct 2023, 01:04 AM