How to use <update> command to change 2 value at sametime?

vean

Chieftain
Joined
Aug 6, 2007
Messages
15
It seems only 1 <update> will pass the build at same time.
Here's my example: the Longhouse. I want to change it to 120 hammers and +20% building speed.

Code:
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set BuildingProductionModifier="20"/>
        </Update>
    </Buildings>
It works.

Code:
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set Cost="120"/>
        </Update>
    </Buildings>

It works too.

Code:
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set Cost="120"/>
            <Set BuildingProductionModifier="20"/>
        </Update>
    </Buildings>

It doesn't work...

Code:
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set Cost="120"/>
        </Update>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set BuildingProductionModifier="20"/>
        </Update>
    </Buildings>

Doesn't work too.

Code:
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set Cost="120"/>
        </Update>
        <Row>
            <Type>BUILDING_LONGHOUSE</Type>
            <BuildingProductionModifier>20</BuildingProductionModifier>
        </Row>
    </Buildings>

Doesn't work again...

I don't know what's the right code. How can I update 2 or more values at sametime?
 
Strangely on Kael's Modding Guide he gives examples that we could do Updates with X 'Sets' when using one Where condition,] but I'm starting to think we can't. (reason next post) I've tried that without success, as PTM on this thread: http://forums.civfanatics.com/showthread.php?t=385557

He/She didn't confirmed yet but seems like the same problem.
 
It should work as I understand. I also have problem updating units. Have anyone suceeded in updating units yet? There are none such mod anyhow and with this problem as well I think there might be something wrong somewhere.
 
That means we can only change 1 value by our mod at same time?
Neither by <ROW> or by <Update>?

It sucks...
 
I don't know what's the right code. How can I update 2 or more values at sametime?

Code:
<GameData>
    <Buildings>
        <Update>
            <Where Type="BUILDING_LONGHOUSE"/>
            <Set Cost="120" BuildingProductionModifier="20"/>
        </Update>
    </Buildings>
</GameData>

That should work. It's the same way I updated two things at once.
 
Thanks LoneGamer, good to know!

I did a mistake too, Kael didn't give any examples like that I said on his guide. What he did was an example with multiple conditions on Where, but using that syntax LoneGamer used on Set too.

Sorry my mistake there =]
 
It works!

Thanks very much!!

They never said this command in pdf files...
 
Back
Top Bottom