Fallout 2 mod FO2 Engine Tweaks (Sfall)

Glovz said:
Just for clarification - this script would affect all files within a map at once or can this be used to address a specific file - say a .pro?

Please forgive me if the answer is obvious but I not really a scriptor.
Yes, it is rather obvious. You didn't even need to look at the script at all. As I said above the script, it affects color.pal. :P

Yes, you could use the same functions to edit a single pro, if that was what you were getting at.

marlboroo said:
but there is a little bug (dunno if this is a bug or not).. seems my perk also effect other party members, so if i have quick pocket perk then party members also use 2 ap to acces inventory, is this a bug or intentional?
It's a bug, but it's not really fixable. The method to control other npcs is rather hacky, and there are more problems with it that just that. It's not really suitable for general use.

Drelm287 said:
That mean I can create new music to fallout without using very old dos programs (wich don't work in new OS like vista and 7) to convert the .mp3, .wav file to .acm? :shock:
Yes.

Nirran said:
possible to add a LIST_SCENERYITEMS?
Done, and in svn. (along with LIST_WALLS, LIST_MISC and LIST_ALL.)

Nirran said:
edit : get_uptime compiles,but it crashes the game,with memory adress fffffff(could not be read)
urk. I wonder if that's ever worked... Fixed in svn, and thanks for pointing that out.
 
Timeslip said:
Nirran said:
]possible to add a LIST_SCENERYITEMS?
Done, and in svn. (along with LIST_WALLS, LIST_MISC and LIST_ALL.)

Nirran said:
edit : get_uptime compiles,but it crashes the game,with memory adress fffffff(could not be read)
urk. I wonder if that's ever worked... Fixed in svn, and thanks for pointing that out.

aesome thanks

edit : question,happen to have the source code and a compiler that will compile the source(or point me to one),from the decompiler you worked on a few years back?like to dabble with it,maybe will be able to keep an updated version for all new releases of sfall(maybe reaching too high)

Nirran
 
Timeslip said:
Glovz said:
Just for clarification - this script would affect all files within a map at once or can this be used to address a specific file - say a .pro?

Please forgive me if the answer is obvious but I not really a scriptor.
Yes, it is rather obvious. You didn't even need to look at the script at all. As I said above the script, it affects color.pal. :P

Yes, you could use the same functions to edit a single pro, if that was what you were getting at.
:) I was pretty sure of what your answers were going to be, but better to ask dumb questions than to make dumb assumptions. :)

To all:
This means that all critters, items, and scenery (just about anything that appears on a map) could have it's colors altered programmatically.

However, I can see it becoming tricky (if at all possible) to have say blue combat armor critters show up on a map with green combat armor critters at the same time.
 
Nirran said:
edit : question,happen to have the source code and a compiler that will compile the source(or point me to one),from the decompiler you worked on a few years back?like to dabble with it,maybe will be able to keep an updated version for all new releases of sfall(maybe reaching too high)
I've never worked on the decompiler. iirc it was Jordan that originally started adding the sfall opcodes to it. In any case, take a look over at teamx.ru. The thread was over there somewhere.
 
Timeslip said:
Nirran said:
edit : question,happen to have the source code and a compiler that will compile the source(or point me to one),from the decompiler you worked on a few years back?like to dabble with it,maybe will be able to keep an updated version for all new releases of sfall(maybe reaching too high)
I've never worked on the decompiler. iirc it was Jordan that originally started adding the sfall opcodes to it. In any case, take a look over at teamx.ru. The thread was over there somewhere.

thanks

edit : possible to add a set_proto_data for object ptrs and not all instances of the pid?current one affects all pid of the same number,could be used to set items in dude inven cost to prevent massive buildup of cash,if not dont sweat it

edit : is it possible to change the way bartering items cost for sale is done?i would like to scale the items below the amount specified in the pro files,again if not easily done forget it

Nirran
 
I have some usability requests, no idea how much trouble it were to implement these features. Don't even know if it's possible at all, but at least I haven't seen these suggestions here.

1. A 'take all' key. I know there's a take all button, I mean a physical key I can configure that takes all.

2. Currently the mouse wheel is mapped to uparrow and downarrow so we can scroll the inventory with it (depending on the ddraw.ini setting). It would be awesome if using the mouse wheel while being on the map would scroll the status window instead of scrolling the map.

3. Pressing the Inventory or the Skilldex key will open and close the respective window.
 
since you mentioned that you have been working on the compiler(@Timeslip) i know of one error,when using heal_critter,and compile with the sfall compiler,then decompile with ruby,void(asm code) is placed on the next line(not detectable except when decompiling with ruby)as the visual studios i am using is 2005(no way I am spending 1k for 2010),I am unable to correct it,anyway thought you should know

the ruby files are on my ftp,pm me f you forgot the loggin info,and you are interested(that version of ruby works in win7)

edit : mind downloading decompile and look at my test script,i want to add all the fo2 opcodes to the decompile script(script compiles with sfall compiler,but fails to decompile),what files have the info i would need to be able to add those missing opcodes?(in compile project),if you dont want to dont sweat it

edit : belay last edit,figured it out

Nirran
 
Nirran said:
i know of one error,when using heal_critter,and compile with the sfall compiler...
Is that a compiler or decompiler error? (I assume you mean critter_heal, since there's no such function as heal_critter.) It is a slightly odd function because sslc will recognise it as both an expression or a statement, which probably isn't necessary, but it doesn't look obviously incorrect in the compiler side.

Nirran said:
(no way I am spending 1k for 2010)
http://www.microsoft.com/express/Windows/

Or, if you happen to have a .edu or .ac.uk email address: https://www.dreamspark.com/Products/Product.aspx?ProductId=25

The only reason anyone would ever pay full price for visual studio is if it's being used commercially. (And even then, there's still bizspark.)
 
Timeslip said:
Nirran said:
i know of one error,when using heal_critter,and compile with the sfall compiler...
Is that a compiler or decompiler error? (I assume you mean critter_heal, since there's no such function as heal_critter.) It is a slightly odd function because sslc will recognise it as both an expression or a statement, which probably isn't necessary, but it doesn't look obviously incorrect in the compiler side.

Nirran said:
(no way I am spending 1k for 2010)
http://www.microsoft.com/express/Windows/

Or, if you happen to have a .edu or .ac.uk email address: https://www.dreamspark.com/Products/Product.aspx?ProductId=25

The only reason anyone would ever pay full price for visual studio is if it's being used commercially. (And even then, there's still bizspark.)

thank you,it must be a ruby problem,i dont have any problems with that function in compiling,decompiling or useing it,only thing is ruby creates a viod op code right under it,maybe it is a compile if anything,but either way,it works,:)

Nirran
 
Nirran said:
edit : possible to add a set_proto_data for object ptrs and not all instances of the pid?current one affects all pid of the same number,could be used to set items in dude inven cost to prevent massive buildup of cash,if not dont sweat it
Not possible. Fallout only loads one copy of each proto, so the data is shared between all instances created from that proto.

Nirran said:
edit : is it possible to change the way bartering items cost for sale is done?i would like to scale the items below the amount specified in the pro files,again if not easily done forget it
Never tried modding the barter system, so no idea. My first thought would be to hook-script it.

Nirran said:
thank you,it must be a ruby problem,i dont have any problems with that function in compiling,decompiling or useing it,only thing is ruby creates a viod op code right under it,maybe it is a compile if anything,but either way,it works,:)
Underneath it? Yeah, it's just ruby then. When it's used as a statement, because the function is actually an expression sslc emits another instruction after it to eat the return value, but that doesn't do anything. It's probably that that you're seeing.
 
found a few errors in the code,these 4 functions will error on compile

Code:
playMoveAlpha(integer, integer);
compiler claims sythax error ->addRegion(integer);
is ignored by the compiler,with and without it in the script,the size of the int file is exactly the same ->	addButtonFlag(integer, integer); 
pre_integer := tokenize(integer, integer, integer);

edit : happen to know the op_codes for these?(offsets)
Code:
	addRegionProc(integer, integer, integer, integer, integer);
	addRegionRightProc(integer, integer, integer);
	deleteRegion(integer);
	activateRegion(integer, integer);
	pre_integer := checkRegion(integer);
[/code'

Nirran
 
Nirran said:
found a few errors in the code,these 4 functions will error on compile

Code:
playMoveAlpha(integer, integer);
You're mising an i there. I was about to blame your problem on that since everything looked fine in sslc, but it in fact turned out to be that playMovieAlphaRect had a copy/paste error and was using the wrong token, overwriting the playMovieAlpha function. You should have noticed that PlayMovieAlphaRect was miscompiling too. (It should have complained about too many function arguments if you gave it all 6.) Fixed.

Nirran said:
Code:
compiler claims sythax error ->addRegion(integer);
That one is... special. It has some weird and unique handling in the compiler. I don't think it can be used as an ordinary function.

The following comment from the sslc source may be useful:
Code:
	// regions are defined as:
	//
	//   region "name", { x, y, x, y, x, y, x, y };
	//
	// meaning if the mouse is clicked in the region defined by the
	// list of points, procedureName is called.
	//
	// Regions are related to the currently selected window.

Nirran said:
Code:
is ignored by the compiler,with and without it in the script,the size of the int file is exactly the same ->	addButtonFlag(integer, integer);
That's looks like it may have been deliberately removed from the compiler, although it's hard to say for sure. I've added it back in, but protected it with the backwards compatibility flag, so that compiling with -b will cause it to be treated in the same way as before.

Nirran said:
Code:
pre_integer := tokenize(integer, integer, integer);
That one's missing from the compiler completely. You can use 2.8's string_split function to do the same thing, but since I noticed over at teamx.ru that tokenize has been tested and found to work, I'll add it back in. (Also protected by the flag, since it's a new token.)

Nirran said:
edit : happen to know the op_codes for these?(offsets)
Code:
	addRegionProc(integer, integer, integer, integer, integer);
	addRegionRightProc(integer, integer, integer);
	deleteRegion(integer);
	activateRegion(integer, integer);
	pre_integer := checkRegion(integer);
0x8081, 0x8082, 0x8083, 0x8084 and 0x8085 respectively.
 
Timeslip said:
Nirran said:
found a few errors in the code,these 4 functions will error on compile

Code:
playMoveAlpha(integer, integer);
You're mising an i there. I was about to blame your problem on that since everything looked fine in sslc, but it in fact turned out to be that playMovieAlphaRect had a copy/paste error and was using the wrong token, overwriting the playMovieAlpha function. You should have noticed that PlayMovieAlphaRect was miscompiling too. (It should have complained about too many function arguments if you gave it all 6.) Fixed.

Nirran said:
Code:
compiler claims sythax error ->addRegion(integer);
That one is... special. It has some weird and unique handling in the compiler. I don't think it can be used as an ordinary function.

The following comment from the sslc source may be useful:
Code:
	// regions are defined as:
	//
	//   region "name", { x, y, x, y, x, y, x, y };
	//
	// meaning if the mouse is clicked in the region defined by the
	// list of points, procedureName is called.
	//
	// Regions are related to the currently selected window.

Nirran said:
Code:
is ignored by the compiler,with and without it in the script,the size of the int file is exactly the same ->	addButtonFlag(integer, integer);
That's looks like it may have been deliberately removed from the compiler, although it's hard to say for sure. I've added it back in, but protected it with the backwards compatibility flag, so that compiling with -b will cause it to be treated in the same way as before.

Nirran said:
Code:
pre_integer := tokenize(integer, integer, integer);
That one's missing from the compiler completely. You can use 2.8's string_split function to do the same thing, but since I noticed over at teamx.ru that tokenize has been tested and found to work, I'll add it back in. (Also protected by the flag, since it's a new token.)

Nirran said:
edit : happen to know the op_codes for these?(offsets)
Code:
	addRegionProc(integer, integer, integer, integer, integer);
	addRegionRightProc(integer, integer, integer);
	deleteRegion(integer);
	activateRegion(integer, integer);
	pre_integer := checkRegion(integer);
0x8081, 0x8082, 0x8083, 0x8084 and 0x8085 respectively.

thank you much Timeslip

Nirran
 
have a list of the op_codes?please dirrect me to it,if not what is the op_code name for 0x807e?(its the only ruby code i dont know of now)

Nirran
 
Nirran said:
have a list of the op_codes?please dirrect me to it.
In the sslc source code, (in the modders pack in the sslc directory,) look at opcodes.h, oplib.h and opextra.h. (They don't contain explicit numbers, just a sequential list of the opcodes. In visual studio you can hover the mouse over each one the see the opcode it represents.)
 
Timeslip said:
Nirran said:
have a list of the op_codes?please dirrect me to it.
In the sslc source code, (in the modders pack in the sslc directory,) look at opcodes.h, oplib.h and opextra.h. (They don't contain explicit numbers, just a sequential list of the opcodes. In visual studio you can hover the mouse over each one the see the opcode it represents.)

Thanks!

edit : ack it lists a decimal,need to get vs10 :(

Nirran
 
Nirran said:
edit : ack it lists a decimal,need to get vs10 :(
vs2010 lists decimals too. It's not exactly difficult to convert between decimal and hex. :shrug:

In case you can't, use the standard windows calculator. Type in a decimal number, click the hex button, and a hex number pops out.
 
Timeslip said:
Nirran said:
edit : ack it lists a decimal,need to get vs10 :(
vs2010 lists decimals too. It's not exactly difficult to convert between decimal and hex. :shrug:

In case you can't, use the standard windows calculator. Type in a decimal number, click the hex button, and a hex number pops out.

already did it,i think the vanilla op_codes in ruby are fucked,vs2005 shows 807e and in the rruby files it is the one i want to find a name for,ack,but others seem to be working,gonna have to recheck all the freaking vanilla numbers

edit : fixed it,thanks for the help(was looking at the wrong file

Nirran
 
playmoviealpharect decompiles into playmoviealpha(one of the broken ones) i dont think the problem is in the decompiler,i double check the text and positioning of the op_codes,seems right(possible im wrong)

edit : pretty sure it is in the compiler,it shows 807d for playmoviealpha,and both int2ssl and ruby show that as playmovieapharect

Nirran
 
Nirran said:
playmoviealpharect decompiles into playmoviealpha(one of the broken ones) i dont think the problem is in the decompiler,i double check the text and positioning of the op_codes,seems right(possible im wrong)

edit : pretty sure it is in the compiler,it shows 807d for playmoviealpha,and both int2ssl and ruby show that as playmovieapharect

Nirran
The compiler was wrong, but the decompilers have both been infected by the wrongness. 807d is playmoviealpha, (a 2 argument function,) 807e is playmoviealpharect. (A 6 argument function.) The compiler had a bug which caused it to compile playmoviealpharect as playmoviealpha, and to not compile playmoviealpha at all. The bug isn't in the opcodes; it was in the bit that converted the string "playmoviealpharect" into an opcode, so the opcodes you see in oplib.h are correct.
 
Back
Top