3UC/4UC for VP: Project Coordination Thread

Status
Not open for further replies.
No, the ability to conduct a diplomatic mission cannot be granted with a promotion. And automatically occurring when next to a city-state is too weird.
Not possible, right.

Okay, so the next question Do we want Germany to be able to convert barbs, or do we want Germany to have an early diplomatic boost?

Instead of straight unit conversion, Slaganz could maybe do this:

Slaganz:
7 :c5strength:CS
Furor Teutonicus: 50% vs barbarians. Not lost on promotion.
Native Tongue promotion: On killing a barbarian unit, 50% chance of spawning an Oathsworn unit. Lost on promotion

Oathsworn:
same unit model as Slaganz, different unit flag
melee unit
8-9:c5strength:CS (1 or 2 more than Slaganz)
Druhtiz Oath Unit action: When adjacent to City-State, consumes unit and receive 10 :c5influence:influence with City-State

On paper, Oathsworn would be more dangerous vs another civ, but slaganz would have greater power vs barbarians with Furor Teutonicus. You can use the two in tandem to take out more barbarians, then dispose of excess oathsworn for influence

Unit icon and flag taken from arminius mod
Spoiler :
upload_2018-1-21_23-0-49.png


Obviously, this could mostly be a re-using of the Eagle's war captives code.

Trying to think of solutions. I think the diplomatic boost is a better match for Germany and is more unique than giving them a poor-man's version of the Hunnic UA
Re: Morocco: I could add the ability to cross borders back to the Corsair if we agree on it. But letting it pillage improvements without declaring war would be very difficult, if at all possible, and would be too disruptive.
Yeah that looked way too difficult. I like the "can enter enemy territory", it allows Morocco to be able to enter open sea if they are bottlenecked into a strait, or get at difficult to reach trade routes to plunder. I think it's a good idea.
The pillage without war is too far though, I also agree with you there, BG

EDIT: as per the discussion in the Morocco balance thread, the ability to enter rival territory would also allow Morocco to screw with internal trade routes, which is just pure evil. :satan:
 
Last edited:
@Infixo I saw you changed tile pointed out by notification from bison to city. Wouldn't be better to show where the bison/flax/figs spawn instead of just city?
That is for the negative message, where bison has not spawned. So, you cant point to non-existing tile, right? For positive it has to be bison tile ofc. Or have I mixed them?
 
@Infixo Ahh right. I looked only into changelog.

I'm impressed by your code. So complicated and simplier in one. How much coding experience do you have if I may ask? You used some interesting tricks in there.

Is returning if function faster than making tree of ifs like in my code? I can see you are using such method.
 
Last edited:
@Infixo Ahh right. I looked only into changelog.
I'm impressed by your code. So complicated and simplier in one. How much coding experience do you have if I may ask? You used some interesting tricks in there.
Is returning if function faster than making tree of ifs like in my code? I can see you are using such method.
First of all, your code works. And I am not going to change lke all scripts. But I have a computer science background and see some inefficiencies (list of luxes), sometimes „not elegant” code (e.g. repeated lines of code). Plus I like to practice with Lua.
Lua is interpreted, not compiled. You won’t know many things until the code is actually executed. I try to minimize number of nested ifs because it is very easy to miss one. Plus readability. Golden rule is not more than 3 levels of nesting.
And btw Nilometer turned out to be particularly complicated :) I didn’t notice at first that those placing conditions differ a bit.
As I said - your code works, it is the most important. You need some practise thou. Like usage of functions to avoid copy&paste and DB related stuff.
 
Instead of straight unit conversion, Slaganz could maybe do this:

Slaganz:
7 :c5strength:CS
Furor Teutonicus: 50% vs barbarians. Not lost on promotion.
Native Tongue promotion: On killing a barbarian unit, 50% chance of spawning an Oathsworn unit. Lost on promotion

Oathsworn:
same unit model as Slaganz, different unit flag
melee unit
8-9:c5strength:CS (1 or 2 more than Slaganz)
Druhtiz Oath Unit action: When adjacent to City-State, consumes unit and receive 10 :c5influence:influence with City-State

On paper, Oathsworn would be more dangerous vs another civ, but slaganz would have greater power vs barbarians with Furor Teutonicus. You can use the two in tandem to take out more barbarians, then dispose of excess oathsworn for influence

Unit icon and flag taken from arminius mod Spoiler :
upload_2018-1-21_23-0-49-png.486049


Obviously, this could mostly be a re-using of the Eagle's war captives code.

Trying to think of solutions. I think the diplomatic boost is a better match for Germany and is more unique than giving them a poor-man's version of the Hunnic UA

For the Oathsworn, is it possible to make the unit capable of diplomatic missions like the Emissary (so it would be a military unit, but with the "diplomatic mission" action available) ? If that is possible, I think this would be a preferable option, since it would allow players to use the Oathsworn to defend CStates efficiently (which would be difficult with what pineappledan proposed) and maybe make the AI able to use the unit consistently.
Also, I think the influence bonus should be 20 :c5influence:, not 10, since, with only 50% chance of spawning an Oathsworn, the effect each one brings should feel significant in the early game (and the goal of the unit is to bring early CS alliances to Germany, which would be quite difficult with only 10 :c5influence:).

For the picture for the unit, I find your idea fitting : being diplomatic units, the Oathsworn can have a picture a little more detailed (look at the pictures for the diplomatic units : they are centered around the faces of the units, much more zoomed than for other units).
For the odal rune that you want to use as the unit flag, it is also an interesting idea : the flag for the Slaganz also has the form of an odal, but the pelt that is used in it suggests a brutish/savage nature, while the Oathsworn flag is a "pure odal", symbolizing the aptitude for the unit to serve as a envoy for the Germanic people (the flags could also be inverted, to suggest the "barbaric" origins of the Oathsworns, but I think that the "pure odal" corresponds better to the picture of the Oathsworn, more calm and composed).

Anyway, I like your ideas :)
 
Last edited:
@Infixo can you test PillageBonusStrength attribute on Viking and Longboat promotion? I wanted to use it on Black Tug to totally delete lua from it, but it seems not to work for me. I checked viking and there is not any indication of addition CS % in battle tooltip.

Reworked totally maya.lua (simplify, added technology restriction, fixed some things).
Reworked Black Tug.
Changed small thing in Pogost.
 
For the Oathsworn, is it possible to make the unit capable of diplomatic missions like the Emissary (so it would be a military unit, but with the "diplomatic mission" action available) ? If that is possible, I think this would be a preferable option, since it would allow players to use the Oathsworn to defend CStates efficiently (which would be difficult with what pineappledan proposed) and maybe make the AI able to use the unit consistently.
This is what I proposed. It is a military unit (either 8 or 9 CS) that has an emissary action as a unit action.

Edit: sorry, modified emissary action. I wouldn't suggest that Oathsworn should get the 1:c5gold:pt, that could get broken pretty fast.
Also, I think the influence bonus should be 20 :c5influence:, not 10, since, with only 50% chance of spawning an Oathsworn, the effect each one brings should feel significant in the early game (and the goal of the unit is to bring early CS alliances to Germany, which would be quite difficult with only 10 :c5influence:).
I think 10 is the sweet spot. 2x as much as a CS gift, but 1/2 as much as a real diplo unit.
The Emissary, available at Writing, a full era later, and gives 20:c5influence: and cannot defend itself like the Oathsworn can. You also get oathsworn effectively for free.
Also keep in mind that it is actually fairly easy to get CS allies with barb hunting alone in ancient/classical. Oathsworn would be useful for maintaining those ties, or bumping a CS friend up to an ally. I don't think they need that much influence to get the job done, and we have't entertained more than 10 :c5influence: in early game before this.

We will see what BG thinks
 
Last edited:
This is what I proposed. It is a military unit (either 8 or 9 CS) that has an emissary action as a unit action.

Ok, there was a misunderstanding from me (although I don't think the condition you put for the "Druhtiz Oath Unit action" is necessary : why not simply give the unit the same "diplomatic mission action" as the one diplo units have (so the unit could be consumed whenever in the territory of a non-hostile CS). This would give something like this :

Oathsworn
9 :c5strength: CP (I prefer this to 8 :c5strength: CP, but tweaks can be done, as always)
Has access to the "Diplomatic mission" action (in the territory of a non-hostile CS, the unit can be consumed to grant 0 :c5influence: influence with that CS and 1 :c5gold: gold)
Has the "Druhtiz Oath" promotion (+10 :c5influence: from "diplomatic mission").

I think 10 is the sweet spot. 2x as much as a CS gift, but 1/2 as much as a real diplo unit.
The Emissary, available at Writing, a full era later, and gives 20:c5influence: and cannot defend itself like the Oathsworn can. You also get oathsworn effectively for free.
Also keep in mind that it is actually fairly easy to get CS allies with barb hunting alone in ancient/classical. Oathsworn would be useful for maintaining those ties, or bumping a CS friend up to an ally. I don't think they need that much influence to get the job done, and we have't entertained more than 10 :c5influence: in early game before this.

Let's do this. If it proves too unreliable, quick tweaks can be done anyway.

What do you think, @Blue Ghost ?
 
Re: Maya calendar
There is a method Player:GetMayaCalendarString(). It returns formated string:
Code:
szRtnValue.Format("%d.%d.%d.%d.%d", m_iBaktun, m_iKatun, m_iTun, m_iWinal, m_iKin);
Since all numbers are integers, and "." is separator so it is easy to get components using string.sub() and string.find().

Or if somebody wants to calculate all from scratch:
Code:
void CvPlayerTraits::ComputeMayaDate()
{
   float fCalendarStart = CALENDAR_START; // -3112.3973f; Actual date is August 11, 3114 BCE.  This float is reversed engineered to come out to Dec 21, 2012 as 13.0.0.0.0
   int iYear = GC.getGame().getGameTurnYear();
   float fYear = (float)iYear;

   if(fYear >= fCalendarStart)
   {
       // Days since calendar start
       float fDays = (fYear - fCalendarStart) * DAYS_IN_YEAR; // 365.242199
       m_iBaktun = (int)(fDays / DAYS_IN_BAKTUN);
       fDays = fDays - ((float)m_iBaktun * DAYS_IN_BAKTUN); // 144000
       m_iKatun = (int)(fDays / DAYS_IN_KATUN);
       fDays = fDays - ((float)m_iKatun * DAYS_IN_KATUN); // 7200
       m_iTun = (int)(fDays / DAYS_IN_TUN);
       fDays = fDays - ((float)m_iTun * DAYS_IN_TUN); // 360
       m_iWinal = (int)(fDays / DAYS_IN_WINAL);
       fDays = fDays - ((float)m_iWinal * DAYS_IN_WINAL); // 20
       m_iKin = (int)fDays;
   }
}
 
@Infixo can you test PillageBonusStrength attribute on Viking and Longboat promotion? I wanted to use it on Black Tug to totally delete lua from it, but it seems not to work for me. I checked viking and there is not any indication of addition CS % in battle tooltip.
I only said about XP gains from pillaging. CS boost is not supported by engine, so PillageBonusStrength must stay.
 
At that early stage of the game, 1 gpt for a diplomatic action that you got for free sounds pretty broken to me. A single point of gold In ancient could increase your gpt on empire by 5-10%. That gold will have a very long, felt impact.
 
Hippodrome change.
Circus maximus now 0 base happiness and 1 happiness on every arena on empire.

decent buff for Hippodrome
 
@Infixo I managed to use your suggestions about Maya Calendar. @FoxOfWar now the table are not necessary, but thank you for your support with looking for Baktun Turns. I really appreciate that.

I tried to add specific notifications for Pogost: one after building construction and one after tech research. I found:
Code:
NOTIFICATION_TECH_AWARD
    Icon
        Tech icon
    Sound
        No Description Available
    Left-Click
        Tech popup
    Extra Parameter 1
        No Description Available
    Extra Parameter 2
        Tech ID
for tech but couldn't make it work (show tech icon). NOTIFICATION_PRODUCTION is also useless because it is just that big orange hammer icon. For Mayas Baktun I didn't found anything suitable.
 
Timing, I has it. I just finished my Epic Maya game (B'ak'tun #13 on turn 676, fyi) xD

On a sidenote, boy does Epic feel fast when you're used to Marathon. Lot of times where I was 'bwuh? Next era already?'

Righty-o. Gonna start a fresh game with a civ that is definitely not Maya or Morocco :P
 
I both hated and loved playing on Standard during the "discovery of several scaling issues" in the last week.

It was fun to see my strategies played out more quickly, but my God Standard killed any sense of immersion I had
 
@pineappledan I will add missing arena culture from Hippodrome and leave +1 Base Happiness so Hippodrome will strt with flat 1 Hap.
 
I will add missing arena culture from Hippodrome and leave +1 Base Happiness so Hippodrome will strt with flat 1 Hap.
By culture on Arenas I think you mean happiness?
Yeah, I think base 1 happiness is good. I just checked the code, no changes required there.
 
At that early stage of the game, 1 gpt for a diplomatic action that you got for free sounds pretty broken to me. A single point of gold In ancient could increase your gpt on empire by 5-10%. That gold will have a very long, felt impact.

You didn't understand what I was refering to : ingame, currently, whenever a unit (diplomatic unit or GMerchant) does a diplomatic mission, the base gains are 0 influence and 1 gold. After that, the promotions of the unit dictates what will be the additionnal gains in influence or gold (for the GMerchant, it is a huge sum of gold added to the base 1 gold, while for the diplomatic units, it is influence).
The 1 gold is maybe a hard-coded elements of the base game, but you can verify : whenever you do a diplomatic mission, there will always be a gain of 1 gold.
So, in the end, the Oathsworn would only have a normal diplomatic mission action available with a gain of 10 :c5influence: (and 1 :c5gold:, because it is the usual thing with diplomatic missions).
 
Regarding Hippodrome: could we make it spawn horses instead of granting horses? Would synergize with the culture on horse tiles.
 
Status
Not open for further replies.
Back
Top Bottom