Specifying defence per terrain for custom units

Having trouble with the game? Report issues and get help here. Read this first!

Moderator: Forum Moderators

Forum rules
Before reporting issues in this section, you must read the following topic:
Post Reply
User avatar
santi
Lord of Wesmere
Posts: 1320
Joined: April 6th, 2004, 12:32 pm

Specifying defence per terrain for custom units

Post by santi »

Ok, I know how to do that, except I forget all possible terrains sometimes
so I wonder is there a way to tell it to get default values for example
if the unit is an elf, from the elf defence values for say forest or snow or ice or whatever?
fmunoz
Founding Artist
Posts: 1469
Joined: August 17th, 2003, 10:04 am
Location: Spain
Contact:

Post by fmunoz »

Yes.. just give the same movetype and add the differences after it.
Go open, the lets say, the elf figther unit file... inside a #ifdef block you will se how he gets less defense than normal nimbler elves. Dont copy the #part just the one inside the [defence] tags.
User avatar
Noyga
Inactive Developer
Posts: 1790
Joined: September 26th, 2005, 5:56 pm
Location: France

Post by Noyga »

Default values should be handled in the movetype.
User avatar
santi
Lord of Wesmere
Posts: 1320
Joined: April 6th, 2004, 12:32 pm

Post by santi »

Ok, in the meantime the unit in question is Elvish Lord +Elvish High Lord
I noticed the oponent gets a 0-0 stats when I am attacking and I have 0-0 stats when defending in some terrains. So, it is an issue of specifying these terrains. But I thought of a hack, just copy over the unit files from HttT. But it still does not fix the problem, so either
- this is because I am playing from the previous scenario instead of the
scenario where this unit is introduced
-there are some additional files in HttT that I did not copy

?
Jgrr
Posts: 121
Joined: June 19th, 2006, 5:53 pm
Location: Espoo, Finland

Post by Jgrr »

santi wrote: I noticed the oponent gets a 0-0 stats when I am attacking and I have 0-0 stats when defending in some terrains.
This sounds like you have a version conflict. In the stable version (1.0.2), the ranges are "short" and "long", in the development version 1.1.7, the ranges are "melee" and "ranged". The ranges should be identical for a retaliation attack to be allowed.
User avatar
santi
Lord of Wesmere
Posts: 1320
Joined: April 6th, 2004, 12:32 pm

Post by santi »

no, the ranged and melee are used. Unless perhaps these are loaded at the very start of the campaign, which I doubt..
Post Reply