|
Thread: Change Towns Line-Up | |
|
cronex

 

Hired Hero
C# Coder
|
posted March 30, 2019 11:32 AM |
|
|
Change Towns Line-Up
Hey!
I was wondering if any of you know if there is a tutorial available to change the towns lineup ?
I'm aware that there is one tutorial that shows you how to do it, but for one map only.
I want to change the line up permanent.
Thanks in advance,
Cronex.
____________
Treat others the way you want to
be treated.
|
|
Macron1

 
    
Supreme Hero
|
posted March 30, 2019 11:53 AM |
|
|
cronex said: Hey!
I was wondering if any of you know if there is a tutorial available to change the towns lineup ?
I'm aware that there is one tutorial that shows you how to do it, but for one map only.
I want to change the line up permanent.
Thanks in advance,
Cronex.
In vcmi you can do it easily.
|
|
cronex

 

Hired Hero
C# Coder
|
posted March 30, 2019 11:55 AM |
|
|
All right, you mind explain?
____________
Treat others the way you want to
be treated.
|
|
Macron1

 
    
Supreme Hero
|
posted March 30, 2019 02:36 PM |
|
|
|
cronex

 

Hired Hero
C# Coder
|
posted April 02, 2019 12:09 PM |
|
|
There we go. Cheers mate.
____________
Treat others the way you want to
be treated.
|
|
dj

  
    
Promising
Supreme Hero
Always loyal to HC
|
posted April 03, 2019 04:48 AM |
|
Edited by dj at 05:57, 03 Apr 2019.
|
If we are still at it.... 
// List of creatures available on each tier. Number of creatures on each tier
// is not hardcoded but it should match with number of dwelling for each level.
// For example structure below would need buildings with these id's:
// first tier: 30 and 37, second tier: 31, third tier: 32, 39, 46
"creatures" :
[
["centaur", "captainCentaur"],
["dwarf"],
["elf", "grandElf", "sharpshooter"],
...
],
Does this mean that the sharpshooter is the 3rd upgrade?
can alternative creatures be represented somehow like this or does it need core scripting?
[
["centaur", "captainCentaur"],
["dwarf"],
[ ["elf", "grandElf", "sharpshooter"], ["x", "y", "z"] ]
...
],
|
|
fiorin

  
   
Promising
Famous Hero
☠️
|
posted April 03, 2019 08:44 PM |
|
Edited by fiorin at 20:46, 03 Apr 2019.
|
dj said: If we are still at it.... 
Does this mean that the sharpshooter is the 3rd upgrade?
can alternative creatures be represented somehow like this or does it need core scripting?
[
["centaur", "captainCentaur"],
["dwarf"],
[ ["elf", "grandElf", "sharpshooter"], ["x", "y", "z"] ]
...
],
That doesnt mean Sharpshooter is 3rd upgraded. Just if on Grand Elf have the upgraded reference. If not, the sharpshooter works like an alternative one on same building.
That way, you can have a bunch of creatures on same building, but not related. Something like a golem factory.
Ps: Of course im talking about VCMI's json. If the question was on Wog script language, just ignore my answer
|
|
AncientDruids

 
   
Famous Hero
(Andruids for short)
|
posted April 04, 2019 02:44 AM |
|
|
dj said: Does this mean that the sharpshooter is the 3rd upgrade?
That's a start, but only a fraction of what you'll have to do. There are also three other things to make the building appear correctly in a town and townhall screens:
- add a building information with certain id in the buildings node (often separate json) of the town json (for 3rd level's second upgrade the id would be 46), or else you won't have an upgraded building to buy Sharpshooters or upgrade Grand Elves.
- add a new def and information about its location in the structures node (often separate json) of the town json, or else your new building won't show on the town screen (but maybe you're ok with that)
- add a new bitmap in the townhall building icons def as a certain frame (same as its id, which would be 46th for 3rd level's second upgrade building) or else you'll get a black rectangle in the townhall building menu. As before, if you're OK with unmodified Upg. Homestead, just copy its frame so that it's 46th in order of frames. If you don't plan to add 2nd upgrades for Centaurs and Dwarfs, just paste whatever in frames 44th and 45th (even Upg. Homestead Icon).
If that sounds too confusing, download one of the town mods that have 2nd upgrades (Abyss and Underworld Castle from the top of my head) and see the sctructure for yourself.
Making alternative creatures in VCMI is somewhat trickier and it essentially requires making 2nd and 3rd upgrades of according levels and making them recruitable in a new dwelling. It's hard to explain, so download one of Ruins' earlier builds with alternative unit to see how it's done.
dj said: [ ["elf", "grandElf", "sharpshooter"], ["x", "y", "z"] ]
- this is definitely not going to work.
|
|
bloodsucker

 
     
Legendary Hero
|
posted April 05, 2019 01:17 AM |
|
|
cronex said: I was wondering if any of you know if there is a tutorial available to change the towns lineup ?
I used the script to turn Conflux into a neutral town (cames in the Wog scripts) and I didn't need anything else but the list of creature Id's that is in the help files.
____________
|
|
|
|