Fallout 2 mod FO2 Engine Tweaks (Sfall)

Heh, I don't know, it's kind of amusing watching these dudes duke it out and attack each other in broken English.
 
Lexx, Jesterka, no comments... Kids...

Timeslip and others - sorry for everything :)

New button code:
Code:
static const DWORD newbuttaction1=0x00443C98;
static void _declspec(naked) newbuttonaction() {
	_asm {
		mov eax,dword ptr ds:[0x510944];
		cmp eax,3;
		jz end_cppf;

      mov edx,1;
		mov eax,0x2B7;
		call newbuttaction1;
end_cppf:
		mov eax,0x502074;
		retn;
	}
}

static const DWORD newbutt1=0x4d87f8;
static const DWORD newbutt2=0x419c88;
static const DWORD newbutt3=0x419188;
static const DWORD newbutt4=0x45e440;
static const DWORD newbutt5=0x419c88;
static const DWORD newbutt6=0x419188;
static const DWORD newbutt7=0x4d8260;
static const DWORD newbutt8=0x45e440;
static const DWORD newbutt9=0x45e440;


static void _declspec(naked) newbuttonfct() {
	_asm {

		mov ebx,0x451990;
		mov edx,0x451988;
		call newbutt1;   
		xor ecx,ecx;     
		push +0x0;       
		mov edx,0x1D6;  //number from intrface.lst for button-up  
		mov eax,0x6;     
		xor ebx,ebx;     
		call newbutt2;   
		mov ecx,0x518f28;
		xor ebx,ebx;     
		xor edx,edx;     
		call newbutt3;   
		mov ds:[0x59d3fc],eax;                                      
		test eax,eax;                                            
		jnz nbtnj1;                                            
		mov edx,0xffffffff;                      
		call newbutt4;                           
		mov eax,edx;                             
		add esp,+0x4;                            
		pop ebp;                                 
		pop edi;                                 
		pop esi;                                 
		pop edx;                                 
		pop ecx;                                 
		pop ebx;                                 
		ret; 
nbtnj1:
		push +0x0;                               
		mov edx,0x1D5;     //number from intrface.lst for button-down                         
		mov eax,0x6;                             
		xor ecx,ecx;                             
		xor ebx,ebx;                             
		call newbutt5;                           
		mov ecx,0x518f2c;                        
		xor ebx,ebx;                                       
		xor edx,edx;                                       
		call newbutt6;                                     
		mov ds:[0x59d400],eax;                                
		test eax,eax;                                      
		jnz nbtnj2;                                      
		mov edx,0xffffffff;                    
		call newbutt9;                         
		mov eax,edx;                           
		add esp,+0x4;                          
		pop ebp;                               
		pop edi;                               
		pop esi;                               
		pop edx;                               
		pop ecx;                               
		pop ebx;                               
		ret; 
nbtnj2:
		push +0x0;                             
		push +0x0;                             
		push eax;                             
		mov edi,ds:[0x59d3fc];                    
		push edi;                              
		push +0x2F;   //returns this value when press                         
		push -0x1;                             
		push -0x1;                             
		push -0x1;                             
		mov ecx,0x29;   //button width                      
		mov ebx,0x13;  //y-position                       
		push +0x13;      //button height                   
		mov edx,0x20E; //x-position                        
		mov eax,ds:[0x519024];                    
		call newbutt7;                         
		mov ds:[0x518f24],eax;                    
		cmp eax,-0x1;                          
		jnz nbtnj3;                          
		mov edx,eax;                           
		call newbutt8;                         
		mov eax,edx;                           
		add esp,+0x4;                          
		pop ebp;                               
		pop edi;                               
		pop esi;                               
		pop edx;                               
		pop ecx;                               
		pop ebx;                               
		ret; 
nbtnj3:
		
		mov ebx,0x451990;
		retn;
	}
}


.......

// skill button x-position
SafeWrite8(0x0045DC04, 0x3F);
// adding new button
SafeWrite8(0x0045DA30, 0xE8);
SafeWrite32(0x0045DA31, ((DWORD)&newbuttonfct) - 0x0045DA35);
// new button event (replace original '/' event. I have no time for something else)
SafeWrite8(0x004437e9, 0xE8);
SafeWrite32(0x004437eA, ((DWORD)&newbuttonaction) - 0x004437ee);
SafeWrite8(0x00443838, 0x90);
SafeWrite32(0x00443839, 0x90909090);
// replace map-button y-position with characters-button y-position
SafeWrite8(0x0045dd40, 0x4e);
SafeWrite8(0x0045de1e, 0x28);
 
M005193b8 (+1) - current slot for save\load
M005186c0 - memory offset. From here start array with GVARs in memory
M005186c4 - total number of GVARs
M0051ddfc - number of cities
M00672e64 - when = 1 - dude moving by the car
M00518f78 - = 0 - active left hand, if = 1 - right
M00510944 - combat flag (3 - combat is active)
M00510940 - counter. total rounds in the combat
 
Lexx, Alray, please, stop this! I deeply respect both of you, but you are behaving like a kids! Don't be jealous. It's a great breakthrough in FO2 modding and now it's available to every modder. It is something we've alvays dreamed of: make our own interface adjustments. And now, when we have this possibility, let's congratulate each other and be happy.

PS Lexx, to be honest this is an insult not for Alray, but for me. I was consulting dozens of modders, but I never, never leaked any information from them to the community. Never. Alray was working on this several month. Alone. Of cource he's insulted by such unjustified hostility. Please, I beg you to understand the situation and stop this. Any of this. We can speak personally if you want and resolve any vagueness left.
 
Alray said:
M005193b8 (+1) - current slot for save\load

M005186c4 - total number of GVARs


heyy, with this you can build a savegame converter, to use fallout 2 slost ind Killaps RP(wheN you do not enter a new map already, right?)
 
Wasteland Ghost said:
PS Lexx, to be honest this is an insult not for Alray, but for me. I was consulting dozens of modders, but I never, never leaked any information from them to the community. Never. Alray was working on this several month. Alone. Of cource he's insulted by such unjustified hostility. Please, I beg you to understand the situation and stop this. Any of this. We can speak personally if you want and resolve any vagueness left.

I didn't said this and I also avoided to say "xy has stolen" like you can see in my first post to this. The reason for this was that I haven't had any possibility to prove this and I also don't say something about others when I am not absolutely sure about it.

Alray's work is a great thing and a pretty good and usefull improvement that I would love to see ingame and also would use for my own mods too and so on.

But then again, we worked hard on our stuff just to see, that it wasn't worth the time now. Depressing, like I already wrote.

Also we made some things different. I am not 100% sure about this, but maybe Helios can take a second look at it and can give improvement suggestions or something like this. But I don't know, how much active he will be in the next time.
 
Doubts can be insulting too. ;) But I wasn't really insulted. I understand your position. I hope everything is perfectly clear now and we can leave this behind and move forward. ;)
 
So, how is the actual status on this? I am also wondering if it is possible to add and or change the position of new buttons without editing the source code and compiling sfall again and so on.
 
I can write. This isn't a problem. The real problem is in events when pressing new button. This must be only in source code of sfall. Or maybe some default event...

I hope you understand my broken english.
 
Yes, your english isn't bad. ;)

Couldn't it be possible to create a new *.ini file with the needed button informations? Sfall could then check the *.ini files in a kind of loop for it's entrys. It would be a bit like the MrFixit recipes.

Some needed informations would be:
- x coordinate
- y coordinate
- position of the button (main menu, game interface, worldmap...)
- button image down
- button image up
- sound when click
- hotkey button (if needed?)
- function that will be called <- this only in sfall? No possibility to "outsource" it?

That's what comes into my mind when I think about it.
 
Hi. These lines are in ddraw.ini

;World map travel time percentage modifier
;Modifies how fast in game time passes while you're moving around the map screen without affecting encounter rate
;The pathfinder fix needs to be turned on for this to work
;100 is normal speed, 0 stops time from passing
WorldMapTimeMod=100

then

;This will change the physical speed at which you move across the map
;Set to 0 to leave at the default. (i.e. limited by vwait in windowed mode, or by processor speed in fullscreen)
;If set to something other than 0, it enforces a maximum fps on the world map screen.
;Changing this to something other than 0 is not recommended if you've already applied a world map speed patch to your fallout exe.
WorldMapFPS=0

;Set to 1 to enable Ray's patch to make world map encounter rate independent of your travel speed
WorldMapEncounterFix=1
WorldMapEncounterRate=5


and


;Obsolete, but can still be used if you know what it does.
;WorldMapDelay=0


--


Especially this "Changing this to something other than 0 is not recommended if you've already applied a world map speed patch to your fallout exe." Is there some exe patch ?

I've found this settings in ddraw.ini in fallout-2-unofficial-fan-patch
WorldMapDelay=16777216

I've combined it with
WorldMapEncounterFix=1
WorldMapEncounterRate=5

but travelling is very slow on slow computers(everything else is as fast as normal)

Is there some real patch to make world map speed independent of computer speed?
 
Is it possible to add support for larger critters (whose base is more than 1 hex) into engine such as robots from fallout tactics? Currently there's some clipping...
 
There are several multi-hex critters in Fallout already: brahmin, radscorpions, deathclaws, centaurs, mole rats, Mr. Handys, security bots.
 
In the mapper you can set one of the flags for a critter to multihex.
There's also an option to set body type to biped, quadruped or robotic. Have you tried any of those?
 
One suggestion for future versions, could you possibly put in a Sound Acceleration setting in SFall? I *ALWAYS* forget to change this setting when playing fallout, it would be nice if you could include this setting?

For example have all 4 settings:

0 - No Acceleration
1 - Basic Acceleration
2 - Standard Acceleration
3 - Full Acceleration

And have the default be 1. You then could stop all the "OMG! All the endings fly by so fast I can't see them!" threads.

Dunno, if this is possible, but would be nice.
 
Did anyone figure *how many* G_VARS can actually be possible in Fallout2?
I do have a serious problem with scripting as I already have posted, maybe this could cause the trouble? Because I never rewrote global.h not even yet, just added and added and... you get what I'm say'en.

Yes i confess, I am hoplessly lazy.
 
Back
Top