| Archer30   
   
   Posts: 1192
 
 | 
			| 
 
				Hah, I understand, Real-life life stuff comes first.  
It seems like RD:I doesn't work at all on HD mod recruit dialog (the dialog called by clicking on the bottom left of town screen). #2/#3/#4 are always -1. 
Possible to improve?
 
Btw I recommend adding a few constants. Came up idea while reading Era 2 Changelog
 Latest ERA mods and scripts in development -  My GitHub
 
				
(This post was last modified: 22.11.2023 05:13 by Archer30.)
 |  | 
	| 22.11.2023 05:13 |  | 
	
		| Berserker   
   
   Posts: 16785
 
 |  | 
	| 22.11.2023 19:45 |  | 
	
		| Valery   
   Posts: 2196
 
 | 
			| 
 
				There is a problem with brute commander after really big fights, instead of giving gold, it takes it, negative value. Is there anything I can do about with erm, or is hardcoded?
			 |  | 
	| 22.11.2023 20:39 |  | 
	
		| Berserker   
   
   Posts: 16785
 
 |  | 
	| 22.11.2023 20:50 |  | 
	
		| Valery   
   Posts: 2196
 
 | 
			| 
 
				So is it possible for me to intercept the overflow then add the maximum gold, like check gold right after last unit was killed then calculate fix in BA1 trigger, by restoring gold first value than add the maximum possible?
 Or check player gold in BA0, then in BA1, restore if less then add the max, would that make sense? Commander gold  comes before or after BA1?
 
				
(This post was last modified: 24.11.2023 01:06 by Valery.)
 |  | 
	| 24.11.2023 01:03 |  | 
	
		| igrik   
   Posts: 2821
 
 |  | 
	| 24.11.2023 03:21 |  | 
	
		| Valery   
   Posts: 2196
 
 | 
			| 
 
				Hi Igrik
 Era has erm hooker active. Is this a script I only have to add in main script? What it does exactly?
 |  | 
	| 24.11.2023 03:28 |  | 
	
		| igrik   
   Posts: 2821
 
 |  | 
	| 25.11.2023 20:28 |  | 
	
		| Berserker   
   
   Posts: 16785
 
 |  | 
	| 25.11.2023 21:05 |  | 
	
		| igrik   
   Posts: 2821
 
 |  | 
	| 25.11.2023 21:50 |  | 
	
		| Berserker   
   
   Posts: 16785
 
 |  | 
	| 26.11.2023 02:18 |  | 
	
		| Valery   
   Posts: 2196
 
 | 
			| 
 
				Ok, which one now?   
And in Igrik example there are two scripts, one in spoiler.  Both are necessary?
			
				
(This post was last modified: 26.11.2023 13:29 by Valery.)
 |  | 
	| 26.11.2023 13:28 |  | 
	
		| Berserker   
   
   Posts: 16785
 
 |  | 
	| 26.11.2023 20:37 |  | 
	
		| XEPOMAHT   
   
   Posts: 2481
 
 | 
			| 
 
				 (26.11.2023 13:28)Valery Wrote:  And in Igrik example there are two scripts, one in spoiler.  Both are necessary? 
Опять костыли для бога костылей? Может быть стоит просто 1 проверку в воговскую функцию добавить:
 
Code:
 void SetRes(int Player,int Nres,int Vres){
 STARTNA(__LINE__, 0)
 int *rp;
 
 if(Vres<0) RETURNV ; нельзя давать отрицательное количество ресурса игроку
 rp=GetResPo(Player,Nres);
 if(rp==0) RETURNV
 *rp=Vres;
 RedrawRes();
 RETURNV
 }
 
Всего лишь подменить функцию по адресу 7100A3h
			 
				
(This post was last modified: 26.11.2023 21:48 by XEPOMAHT.)
 |  | 
	| 26.11.2023 21:47 |  |