Talk:Oni engine patches (Mac PPC): Difference between revisions
m (+cat) |
|||
(13 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
== | ==Mac Daodan== | ||
:What's the possibility of making something [[wikipedia:DLL_injection#Approaches_on_Unix-like_systems|Daodan-like]] for the Mac, or placing function calls in code caves? --[[User:RossyMiles|rossy]] 11:18, 10 October 2008 (CEST) | |||
:Define "code caves"; I'm not sure there's many of those, and we can't go very far with a hackish approach anyway. As for DLL-similar stuff, SFeLi said it was feasible and even relatively easy with [[wikipedia:Mach-O|Mach-O]] files: I haven't looked into that myself. --[[User:Geyser|geyser]] 18:06, 10 October 2008 (CEST) | |||
::Code caves? There are a ton of those in the Mac executable :) [[User:Neo|Neo]] | |||
:::[[wikt:code_cave]] Sounds neat\useful, for someone who is good at asm.[[User:Gumby|Gumby]] 05:38, 16 October 2008 (CEST) | |||
---- | ---- | ||
==Uppercase letters at the console== | |||
:''Issue still unsolved as of 06:39, 22 October 2008 (CEST) | |||
Hmm, about the Shift key not being 'accessible'... I actually never noticed before that one cannot type capital letters on the command line, and if I did notice it I would have assumed the PC version was the same. So, one point and one question: | Hmm, about the Shift key not being 'accessible'... I actually never noticed before that one cannot type capital letters on the command line, and if I did notice it I would have assumed the PC version was the same. So, one point and one question: | ||
*It's not exactly true that the Shift key is not accessible or not recognized, because I can type important characters like the underscore and parentheses. It's merely that uppercase letters cannot be typed. | *It's not exactly true that the Shift key is not accessible or not recognized, because I can type important characters like the underscore and parentheses. It's merely that uppercase letters cannot be typed. | ||
Line 130: | Line 20: | ||
::[[User:Geyser|geyser]] 03:36, 7 October 2008 (CEST) | ::[[User:Geyser|geyser]] 03:36, 7 October 2008 (CEST) | ||
:::Just confirmed it to make sure; only a-z cannot be modified by the Shift key, i.e., become uppercase. All other characters that require Shift can be typed. And thanks for the answer on what uses uppercase, the team names and AI names slipped my mind. I tested that as well, hoping that the Mac would ignore case, but alas; the console indeed does not recognize any team names without the uppercase letters. --[[User:Iritscen|Iritscen]] 04:02, 7 October 2008 (CEST) | :::Just confirmed it to make sure; only a-z cannot be modified by the Shift key, i.e., become uppercase. All other characters that require Shift can be typed. And thanks for the answer on what uses uppercase, the team names and AI names slipped my mind. I tested that as well, hoping that the Mac would ignore case, but alas; the console indeed does not recognize any team names without the uppercase letters. --[[User:Iritscen|Iritscen]] 04:02, 7 October 2008 (CEST) | ||
:::::::Iritscen, you beat me to it. The SHIFT key does not work in Dev Mode to enter uppercase letters (I should have been more specific, sorry). How long have I've known these issues? The SHIFT key problem was discovered when you, (geyser) asked me to enter some code in the console, I forgot when that happened. The Window mode issue was known as soon as it was figured out how to run Omni group's version in a window. I'm sure this was mentioned at some point, either here or at OCF. The problems with the Numpad key was known back in Jan 2007 and you suggested using the [ | :::Also, I now see that capitals are required to type in animation names, therefore the chr_animate command is essentially unuseable on the Mac Oni console line; however, the command still works from within a BSL script, where caps are recognized. --[[User:Iritscen|iritscen]] 06:01, 7 November 2008 (CET) | ||
::::Iritscen, you beat me to it. The SHIFT key does not work in Dev Mode to enter uppercase letters (I should have been more specific, sorry). How long have I've known these issues? The SHIFT key problem was discovered when you, (geyser) asked me to enter some code in the console, I forgot when that happened. The Window mode issue was known as soon as it was figured out how to run Omni group's version in a window. I'm sure this was mentioned at some point, either here or at OCF. The problems with the Numpad key was known back in Jan 2007 and you suggested using the [[User_talk:EdT|key_config.txt file]] [[User:EdT|EdT]] 04:11, 7 October 2008 (CEST) | |||
---- | |||
==Large textures== | |||
The crash report is now history, but let's clarify the status of the patch at 0x001151C3. Is it irrelevant and can it be reverted? | |||
:0x001151C3 needs to be changed to 0x40 for 1024 textures, reverting to 0x04 or 0x10 results in crashes. Fortunately, I had already changed it to 0x40 prior to the latest patch.[[User:EdT|EdT]] 07:17, 22 October 2008 (CEST) | |||
---- | |||
==Projectile awareness== | |||
Fixed as of Dec 18 2008 | |||
{| | |||
| | |||
{{table}} | |||
{{th}} | |||
!Offset!!Old hex!!New hex!!Description | |||
|-align=center | |||
|0x00016503<BR>0x00016507<BR>0x0001650B<BR>0x000164F1<BR>0x000164F2||50<br>54<br>58<br>9D<br>23||74<br>78<br>7C<br>BD<br>2B | |||
|align=left|projectile awareness fixed | |||
|} | |||
|} | |||
---- | |||
==BSL functions== | ==BSL functions== | ||
Cleaning up previous talk, see history if you need reference | |||
#Redeeming cm_barabus, because it looks like it works after all, and could be useful to both scripters and video makers (basically it interpolates the camera until it focuses on a certain character). So, Ed, please revert it. | |||
#Scrapping all 11 ai2_skill_* functions, because their table entries and strings are conveniently grouped. Putting 11 "essentials" there. If you want to tweak shooting skills, use another version ^_^ | |||
#Keeping chr_holdkey as chr_location for now; may move it around later ^_^ | |||
; | #Turning ai2_panic into equally useless chr_draw_dot; we may change it later ^_^ | ||
#Turning ai2_chump into modder-oriented chr_who; we may change it later ^_^ | |||
#Turning ai2_printbnvindex into ui_fill_element; we may change it later ^_^ | |||
#For the big continuous patch you probably don't want to go nuts doing it byte by byte like I did, so grab a patched engine [http://geyser.oni2.net/TEMP/omni/OniBSL.zip HERE] and copy the relevant sections over to your backup. I used the big table below to proofread the patch, and we may still need it to check function pointers etc if something doesn't work. | |||
{{Table}} style="white-space:nowrap" | {{Table}} style="white-space:nowrap" | ||
|+making ''' | |+making '''ai2_printbnvindex''' into '''ui_fill_element''': fixing pointers | ||
{{th}} | {{th}} | ||
!Offset | !Offset | ||
Line 150: | Line 68: | ||
!Description | !Description | ||
|- | |- | ||
| | |0x1B9BDC | ||
|00 | |00 17 1A 40 | ||
|00 | |00 17 1A 40 | ||
|pointer to BSL name; unchanged | |pointer to BSL name; unchanged | ||
|- | |- | ||
| | |0x1B9BE8 | ||
|00 | |00 17 1A 54 | ||
|00 | |00 17 1A 54 | ||
|pointer to help string; unchanged | |pointer to help string; unchanged | ||
|- | |- | ||
| | |0x1B9BEC | ||
|00 16 | |00 16 A1 48 | ||
|00 | |00 17 86 20 | ||
|pointer to signature string; | |pointer to signature string; redirected | ||
|- | |- | ||
| | |0x1B9BF0 | ||
|00 03 | |00 03 27 DC | ||
|00 ''' | |00 '''07 19 DC''' | ||
|pointer to function; now pointing to | |pointer to function; now pointing to _ONiInGameUI_FillElement | ||
|} | |} | ||
Line 203: | Line 121: | ||
{{Table}} style="white-space:nowrap" | {{Table}} style="white-space:nowrap" | ||
|+making '''ai2_panic''' into ''' | |+making '''ai2_chump''' into '''chr_who''': fixing pointers | ||
{{th}} | |||
!Offset | |||
!Old hex | |||
!New hex | |||
!Description | |||
|- | |||
|0x1B9BF4 | |||
|00 17 1A 7C | |||
|00 17 1A 7C | |||
|pointer to BSL name; unchanged | |||
|- | |||
|0x1B9C00 | |||
|00 17 1A 88 | |||
|00 17 1A 88 | |||
|pointer to help string; unchanged | |||
|- | |||
|0x1B9C04 | |||
|00 16 A1 48 | |||
|00 16 A1 48 | |||
|pointer to signature string; unchanged | |||
|- | |||
|0x1B9C08 | |||
|00 03 2E E0 | |||
|00 '''04 00 88''' | |||
|pointer to function; now pointing to _ONrWho | |||
|} | |||
{{Table}} style="white-space:nowrap" | |||
|+making '''ai2_panic''' into '''chr_draw_dot''': fixing pointers | |||
{{th}} | {{th}} | ||
!Offset | !Offset | ||
Line 227: | Line 175: | ||
|0x1B95F0 | |0x1B95F0 | ||
|00 03 55 F8 | |00 03 55 F8 | ||
|00 '''04 | |00 '''04 15 04''' | ||
|pointer to function; now pointing to | |pointer to function; now pointing to _iDrawDot | ||
|} | |} | ||
{{Table}} style="white-space:nowrap" | {{Table}} style="white-space:nowrap" | ||
|+making ''' | |+making '''ai2_printbnvindex''' into '''ui_fill_element''': fixing strings | ||
{{th}} | {{th}} | ||
!Offset | !Offset | ||
! | !0x170A40 | ||
! | !0x170A54 | ||
|- | |- | ||
!Old chars | !Old chars | ||
|<tt> | |<tt>ai2_printbnvindex°°°</tt> | ||
|<tt> | |<tt>prints the index of the player's BNV°°°°</tt> | ||
|- | |- | ||
!New chars | !New chars | ||
|<tt> | |<tt>ui_fill_element°°°°°</tt> | ||
|<tt> | |<tt>forces a part of the UI to appear full°°</tt> | ||
|- | |- | ||
!Description | !Description | ||
|replacing name | |replacing name in_place | ||
|replacing help string in-place | |replacing help string in-place | ||
|} | |} | ||
Line 283: | Line 227: | ||
{{Table}} style="white-space:nowrap" | {{Table}} style="white-space:nowrap" | ||
|+making '''ai2_panic''' into ''' | |+making '''ai2_chump''' into '''chr_who''': fixing strings | ||
{{th}} | |||
!Offset | |||
!0x170A7C | |||
!0x170A88 | |||
|- | |||
!Old chars | |||
|<tt>ai2_chump°</tt> | |||
|<tt>creates a chump°</tt> | |||
|- | |||
!New chars | |||
|<tt>chr_who°°°</tt> | |||
|<tt>lists all chars°</tt> | |||
|- | |||
!Description | |||
|replacing name in-place | |||
|replacing help string in-place | |||
|} | |||
{{Table}} style="white-space:nowrap" | |||
|+making '''ai2_panic''' into '''chr_draw_dot''': fixing strings | |||
{{th}} | {{th}} | ||
!Offset | !Offset | ||
Line 296: | Line 261: | ||
|- | |- | ||
!New chars | !New chars | ||
|<tt> | |<tt>chr_draw_dot°°</tt> | ||
|<tt> | |<tt>draw line from player to point°°</tt> | ||
|<tt><nowiki> | |<tt><nowiki>[[loc_x:float loc_y:float loc_z:float] | ]°°</nowiki></tt> | ||
|- | |- | ||
!Description | !Description | ||
Line 305: | Line 270: | ||
|replacing signature string in-place | |replacing signature string in-place | ||
|} | |} | ||
{{Table}} style="white-space:nowrap" | {{Table}} style="white-space:nowrap" | ||
|+making ''' | |+making '''ai2_skill_*''' into eleven other funcs: fixing pointers | ||
{{th}} | {{th}} | ||
!Offset | !Offset | ||
Line 326: | Line 279: | ||
!New hex | !New hex | ||
!Description | !Description | ||
|- | |||
|0x1B975C | |||
|00 17 0E 24 | |||
|'''00 17 11 53 | |||
|pointer to BSL name '''chr_focus | |||
|- | |||
|0x1B9768 | |||
|00 17 0E 38 | |||
|'''00 17 10 20 | |||
|pointer to help string | |||
|- | |||
|0x1B976C | |||
|00 17 0E 5C | |||
|'''00 17 11 5D | |||
|pointer to signature string | |||
|- | |||
|0x1B9770 | |||
|00 03 0A 14 | |||
|'''00 04 19 6C | |||
|pointer to function; now pointing to _SetMainCharacter | |||
|- | |||
|0x1B9774 | |||
|00 17 0E 84 | |||
|'''00 17 11 68 | |||
|pointer to BSL name '''powerup_reset | |||
|- | |||
|0x1B9780 | |||
|00 17 0E 94 | |||
|'''00 17 10 4A | |||
|pointer to help string | |||
|- | |||
|0x1B9784 | |||
|00 16 A1 48 | |||
|00 16 A1 48 | |||
|pointer to signature string; unchanged | |||
|- | |||
|0x1B9788 | |||
|00 03 0B 60 | |||
|'''00 0A 57 8C | |||
|pointer to function; now pointing to _WPiPowerups_Reset | |||
|- | |||
|0x1B978C | |||
|00 17 0E C0 | |||
|'''00 17 11 76 | |||
|pointer to BSL name '''corpse_reset | |||
|- | |||
|0x1B9798 | |||
|00 17 0E D4 | |||
|'''00 17 10 64 | |||
|pointer to help string | |||
|- | |||
|0x1B979C | |||
|00 16 A1 48 | |||
|00 16 A1 48 | |||
|pointer to signature string; unchanged | |||
|- | |||
|0x1B97A0 | |||
|00 03 0C DC | |||
|'''00 04 08 A0 | |||
|pointer to function; now pointing to _ONrCorpse_Reset | |||
|- | |- | ||
|0x1B97A4 | |0x1B97A4 | ||
|00 17 0F 10 | |00 17 0F 10 | ||
|00 17 | |'''00 17 11 83 | ||
|pointer to BSL name | |pointer to BSL name '''weapon_reset | ||
|- | |- | ||
|0x1B97B0 | |0x1B97B0 | ||
|00 17 0F 20 | |00 17 0F 20 | ||
|00 17 | |'''00 17 10 7D | ||
|pointer to help string | |pointer to help string | ||
|- | |- | ||
|0x1B97B4 | |0x1B97B4 | ||
Line 344: | Line 357: | ||
|0x1B97B8 | |0x1B97B8 | ||
|00 03 0D 90 | |00 03 0D 90 | ||
| | |'''00 0A 56 38 | ||
|pointer to function; now pointing to _WPiWeapons_Reset | |pointer to function; now pointing to _WPiWeapons_Reset | ||
|- | |- | ||
|0x1B97BC | |||
| | |00 17 0F 5C | ||
| | |'''00 17 11 1E | ||
| | |pointer to BSL name '''chr_set_class | ||
|- | |||
|0x1B97C8 | |||
|00 17 0F 70 | |||
|'''00 17 0F F4 | |||
|pointer to help string | |||
|- | |||
|0x1B97CC | |||
|00 17 0F A0 | |||
|'''00 17 11 2C | |||
|pointer to signature string | |||
|- | |||
|0x1B97D0 | |||
|00 03 0F C0 | |||
|'''00 04 06 14 | |||
|pointer to function; now pointing to _iSetCharacterClass | |||
|- | |||
|0x1B97D4 | |||
|00 17 0F BC | |||
|'''00 17 11 00 | |||
|pointer to BSL name '''chr_health | |||
|- | |||
|0x1B97E0 | |||
|00 17 0F D0 | |||
|'''00 17 0F DD | |||
|pointer to help string | |||
|- | |||
|0x1B97E4 | |||
|00 17 0F FC | |||
|'''00 17 11 0B | |||
|pointer to signature string | |||
|- | |||
|0x1B97E8 | |||
|00 03 10 4C | |||
|'''00 04 18 48 | |||
|pointer to function; now pointing to _iSetAnyCharacterHealth | |||
|- | |||
|0x1B97EC | |||
|00 17 10 10 | |||
|'''00 17 10 EB | |||
|pointer to BSL name '''gs_fov_set | |||
|- | |||
|0x1B97F8 | |||
|00 17 10 20 | |||
|'''00 17 0F B4 | |||
|pointer to help string | |||
|- | |||
|0x1B97FC | |||
|00 17 10 3C | |||
|'''00 17 10 F6 | |||
|pointer to signature string | |||
|- | |||
|0x1B9800 | |||
|00 03 11 38 | |||
|'''00 05 B8 18 | |||
|pointer to function; now pointing to _ONrGameState_FieldOfView_Set | |||
|- | |||
|0x1B9804 | |||
|00 17 10 50 | |||
|'''00 17 10 D3 | |||
|pointer to BSL name '''make_corpse | |||
|- | |||
|0x1B9810 | |||
|00 17 10 60 | |||
|'''00 17 0F 94 | |||
|pointer to help string | |||
|- | |||
|0x1B9814 | |||
|00 17 10 7C | |||
|'''00 17 10 DF | |||
|pointer to signature string | |||
|- | |||
|0x1B9818 | |||
|00 03 11 C4 | |||
|'''00 04 09 24 | |||
|pointer to function; now pointing to _ONrMakeCorpse | |||
|- | |||
|0x1B981C | |||
|00 17 10 90 | |||
|'''00 17 10 BA | |||
|pointer to BSL name '''chr_display_combat_stats | |||
|- | |||
|0x1B9828 | |||
|00 17 10 A8 | |||
|'''00 17 0F 74 | |||
|pointer to help string | |||
|- | |||
|0x1B982C | |||
|00 17 10 D4 | |||
|'''00 17 11 5D | |||
|pointer to signature string | |||
|- | |||
|0x1B9830 | |||
|00 03 12 50 | |||
|'''00 04 04 54 | |||
|pointer to function; now pointing to _iDiplayCharacterCombatStats | |||
|- | |||
|0x1B9834 | |||
|00 17 10 E8 | |||
|'''00 17 10 A1 | |||
|pointer to BSL name '''chr_location_settocamera | |||
|- | |||
|0x1B9840 | |||
|00 17 10 FC | |||
|'''00 17 0F 55 | |||
|pointer to help string | |||
|- | |||
|0x1B9844 | |||
|00 17 11 2C | |||
|'''00 17 11 5D | |||
|pointer to signature string | |||
|- | |||
|0x1B9848 | |||
|00 03 12 DC | |||
|'''00 04 1A AC | |||
|pointer to function; now pointing to _iCharacterLocation_SetFromCamera | |||
|- | |||
|0x1B984C | |||
|00 17 11 3C | |||
|'''00 17 10 96 | |||
|pointer to BSL name '''chr_weapon | |||
|- | |||
|0x1B9858 | |||
|00 17 11 50 | |||
|'''00 17 0F 29 | |||
|pointer to help string | |||
|- | |- | ||
|0x1B985C | |||
| | |00 17 11 80 | ||
| | |'''00 17 11 2C | ||
| | |pointer to signature string | ||
|- | |- | ||
|0x1B9860 | |||
| | |00 03 13 84 | ||
| | |'''00 04 19 E0 | ||
| | |pointer to function; now pointing to _iSetAnyCharacterWeapon | ||
|} | |} | ||
;Replacing ai2_skill_* with eleven other funcs, leaving room for more strings | |||
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F | |||
001B9750 00 17 0E 24 ...$ | |||
001B9760 00 00 00 00 00 00 00 00 00 17 0E 38 00 17 0E 5C ...........8...\ | |||
001B9770 00 03 0A 14 00 17 0E 84 00 00 00 00 00 00 00 00 .......„........ | |||
001B9780 00 17 0E 94 00 16 A1 48 00 03 0B 60 00 17 0E C0 ...”..¡H...`...À | |||
001B9790 00 00 00 00 00 00 00 00 00 17 0E D4 00 16 A1 48 ...........Ô..¡H | |||
001B97A0 00 03 0C DC 00 17 0F 10 00 00 00 00 00 00 00 00 ...Ü............ | |||
001B97B0 00 17 0F 20 00 16 A1 48 00 03 0D 90 00 17 0F 5C ... ..¡H.......\ | |||
001B97C0 00 00 00 00 00 00 00 00 00 17 0F 70 00 17 0F A0 ...........p... | |||
001B97D0 00 03 0F C0 00 17 0F BC 00 00 00 00 00 00 00 00 ...À...¼........ | |||
001B97E0 00 17 0F D0 00 17 0F FC 00 03 10 4C 00 17 10 10 ...Ð...ü...L.... | |||
001B97F0 00 00 00 00 00 00 00 00 00 17 10 20 00 17 10 3C ........... ...< | |||
001B9800 00 03 11 38 00 17 10 50 00 00 00 00 00 00 00 00 ...8...P........ | |||
001B9810 00 17 10 60 00 17 10 7C 00 03 11 C4 00 17 10 90 ...`...|...Ä.... | |||
001B9820 00 00 00 00 00 00 00 00 00 17 10 A8 00 17 10 D4 ...........¨...Ô | |||
001B9830 00 03 12 50 00 17 10 E8 00 00 00 00 00 00 00 00 ...P...è........ | |||
001B9840 00 17 10 FC 00 17 11 2C 00 03 12 DC 00 17 11 3C ...ü...,...Ü...< | |||
001B9850 00 00 00 00 00 00 00 00 00 17 11 50 00 17 11 80 ...........P...€ | |||
001B9860 00 03 13 84 ...„ | |||
must be changed to | |||
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F | |||
001B9750 00 17 11 53 ...S | |||
001B9760 00 00 00 00 00 00 00 00 00 17 10 20 00 17 11 5D ........... ...] | |||
001B9770 00 04 19 6C 00 17 11 68 00 00 00 00 00 00 00 00 ...l...h........ | |||
001B9780 00 17 10 4A 00 16 A1 48 00 0A 57 8C 00 17 11 76 ...J..¡H..WŒ...v | |||
001B9790 00 00 00 00 00 00 00 00 00 17 10 64 00 16 A1 48 ...........d..¡H | |||
001B97A0 00 04 08 A0 00 17 11 83 00 00 00 00 00 00 00 00 ... ...ƒ........ | |||
001B97B0 00 17 10 7D 00 16 A1 48 00 0A 56 38 00 17 11 1E ...}..¡H..V8.... | |||
001B97C0 00 00 00 00 00 00 00 00 00 17 0F F4 00 17 11 2C ...........ô..., | |||
001B97D0 00 04 06 14 00 17 11 00 00 00 00 00 00 00 00 00 ................ | |||
001B97E0 00 17 0F DD 00 17 11 0B 00 04 18 48 00 17 10 EB ...Ý.......H...ë | |||
001B97F0 00 00 00 00 00 00 00 00 00 17 0F B4 00 17 10 F6 ...........´...ö | |||
001B9800 00 05 B8 18 00 17 10 D3 00 00 00 00 00 00 00 00 ..¸....Ó........ | |||
001B9810 00 17 0F 94 00 17 10 DF 00 04 09 24 00 17 10 BA ...”...ß...$...º | |||
001B9820 00 00 00 00 00 00 00 00 00 17 0F 74 00 17 11 5D ...........t...] | |||
001B9830 00 04 04 54 00 17 10 A1 00 00 00 00 00 00 00 00 ...T...¡........ | |||
001B9840 00 17 0F 55 00 17 11 5D 00 04 1A AC 00 17 10 96 ...U...]...¬...– | |||
001B9850 00 00 00 00 00 00 00 00 00 17 0F 29 00 17 11 2C ...........)..., | |||
001B9860 00 04 19 E0 ...à | |||
and | |||
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F | |||
0016FE20 00 00 61 69 32 5F 73 6B 69 6C 6C 5F 73 65 ..ai2_skill_se | |||
0016FE30 6C 65 63 74 00 00 00 00 73 65 6C 65 63 74 73 20 lect....selects | |||
0016FE40 61 20 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C a shooting skill | |||
0016FE50 20 74 6F 20 65 64 69 74 00 00 00 00 63 68 61 72 to edit....char | |||
0016FE60 5F 63 6C 61 73 73 3A 73 74 72 69 6E 67 20 77 65 _class:string we | |||
0016FE70 61 70 6F 6E 5F 6E 61 6D 65 3A 73 74 72 69 6E 67 apon_name:string | |||
0016FE80 00 00 00 00 61 69 32 5F 73 6B 69 6C 6C 5F 73 68 ....ai2_skill_sh | |||
0016FE90 6F 77 00 00 73 68 6F 77 73 20 74 68 65 20 63 75 ow..shows the cu | |||
0016FEA0 72 72 65 6E 74 6C 79 20 73 65 6C 65 63 74 65 64 rrently selected | |||
0016FEB0 20 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C 00 shooting skill. | |||
0016FEC0 61 69 32 5F 73 6B 69 6C 6C 5F 72 65 76 65 72 74 ai2_skill_revert | |||
0016FED0 00 00 00 00 72 65 76 65 72 74 73 20 74 68 65 20 ....reverts the | |||
0016FEE0 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C 20 62 shooting skill b | |||
0016FEF0 65 69 6E 67 20 65 64 69 74 65 64 20 74 6F 20 74 eing edited to t | |||
0016FF00 68 65 20 73 61 76 65 64 20 63 6F 70 79 00 00 00 he saved copy... | |||
0016FF10 61 69 32 5F 73 6B 69 6C 6C 5F 73 61 76 65 00 00 ai2_skill_save.. | |||
0016FF20 73 61 76 65 73 20 74 68 65 20 73 68 6F 6F 74 69 saves the shooti | |||
0016FF30 6E 67 20 73 6B 69 6C 6C 20 62 65 69 6E 67 20 65 ng skill being e | |||
0016FF40 64 69 74 65 64 20 6F 75 74 20 61 73 20 61 20 74 dited out as a t | |||
0016FF50 65 78 74 20 66 69 6C 65 00 00 00 00 61 69 32 5F ext file....ai2_ | |||
0016FF60 73 6B 69 6C 6C 5F 72 65 63 6F 69 6C 00 00 00 00 skill_recoil.... | |||
0016FF70 73 65 74 73 20 61 6E 20 41 49 27 73 20 72 65 63 sets an AI's rec | |||
0016FF80 6F 69 6C 20 63 6F 6D 70 65 6E 73 61 74 69 6F 6E oil compensation | |||
0016FF90 20 61 6D 6F 75 6E 74 20 28 30 2D 31 29 00 00 00 amount (0-1)... | |||
0016FFA0 72 65 63 6F 69 6C 5F 63 6F 6D 70 65 6E 73 61 74 recoil_compensat | |||
0016FFB0 69 6F 6E 3A 66 6C 6F 61 74 00 00 00 61 69 32 5F ion:float...ai2_ | |||
0016FFC0 73 6B 69 6C 6C 5F 62 65 73 74 61 6E 67 6C 65 00 skill_bestangle. | |||
0016FFD0 73 65 74 73 20 61 6E 20 41 49 27 73 20 62 65 73 sets an AI's bes | |||
0016FFE0 74 20 61 69 6D 69 6E 67 20 61 6E 67 6C 65 20 69 t aiming angle i | |||
0016FFF0 6E 20 64 65 67 72 65 65 73 00 00 00 62 65 73 74 n degrees...best | |||
00170000 5F 61 6E 67 6C 65 3A 66 6C 6F 61 74 00 00 00 00 _angle:float.... | |||
00170010 61 69 32 5F 73 6B 69 6C 6C 5F 65 72 72 6F 72 00 ai2_skill_error. | |||
00170020 73 65 74 73 20 61 6E 20 41 49 27 73 20 67 72 6F sets an AI's gro | |||
00170030 75 70 69 6E 67 20 65 72 72 6F 72 00 65 72 72 6F uping error.erro | |||
00170040 72 5F 61 6D 6F 75 6E 74 3A 66 6C 6F 61 74 00 00 r_amount:float.. | |||
00170050 61 69 32 5F 73 6B 69 6C 6C 5F 64 65 63 61 79 00 ai2_skill_decay. | |||
00170060 73 65 74 73 20 61 6E 20 41 49 27 73 20 67 72 6F sets an AI's gro | |||
00170070 75 70 69 6E 67 20 64 65 63 61 79 00 64 65 63 61 uping decay.deca | |||
00170080 79 5F 61 6D 6F 75 6E 74 3A 66 6C 6F 61 74 00 00 y_amount:float.. | |||
00170090 61 69 32 5F 73 6B 69 6C 6C 5F 69 6E 61 63 63 75 ai2_skill_inaccu | |||
001700A0 72 61 63 79 00 00 00 00 73 65 74 73 20 61 6E 20 racy....sets an | |||
001700B0 41 49 27 73 20 73 68 6F 6F 74 69 6E 67 20 69 6E AI's shooting in | |||
001700C0 61 63 63 75 72 61 63 79 20 6D 75 6C 74 69 70 6C accuracy multipl | |||
001700D0 69 65 72 00 69 6E 61 63 63 75 72 61 63 79 3A 66 ier.inaccuracy:f | |||
001700E0 6C 6F 61 74 00 00 00 00 61 69 32 5F 73 6B 69 6C loat....ai2_skil | |||
001700F0 6C 5F 64 65 6C 61 79 6D 69 6E 00 00 73 65 74 73 l_delaymin..sets | |||
00170100 20 61 6E 20 41 49 27 73 20 6D 69 6E 20 64 65 6C an AI's min del | |||
00170110 61 79 20 62 65 74 77 65 65 6E 20 73 68 6F 74 73 ay between shots | |||
00170120 2C 20 69 6E 20 66 72 61 6D 65 73 00 6D 69 6E 64 , in frames.mind | |||
00170130 65 6C 61 79 3A 69 6E 74 00 00 00 00 61 69 32 5F elay:int....ai2_ | |||
00170140 73 6B 69 6C 6C 5F 64 65 6C 61 79 6D 61 78 00 00 skill_delaymax.. | |||
00170150 73 65 74 73 20 61 6E 20 41 49 27 73 20 6D 61 78 sets an AI's max | |||
00170160 20 64 65 6C 61 79 20 62 65 74 77 65 65 6E 20 73 delay between s | |||
00170170 68 6F 74 73 2C 20 69 6E 20 66 72 61 6D 65 73 00 hots, in frames. | |||
00170180 6D 61 78 64 65 6C 61 79 3A 69 6E 74 00 00 00 00 maxdelay:int.... | |||
must be changed to | |||
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F | |||
0016FE20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 .............. | |||
0016FE30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE50 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE60 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE70 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FE90 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FEA0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FEB0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FEC0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FED0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FEE0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FEF0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FF00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FF10 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ | |||
0016FF20 00 00 00 00 00 00 00 00 00 73 65 74 73 20 4F 4E .........sets ON | |||
0016FF30 57 43 20 66 6F 72 20 67 69 76 65 6E 20 63 68 61 WC for given cha | |||
0016FF40 72 61 63 74 65 72 20 62 79 20 6E 61 6D 65 20 6F racter by name o | |||
0016FF50 72 20 69 64 00 74 65 6C 65 70 6F 72 74 73 20 74 r id.teleports t | |||
0016FF60 6F 20 63 61 6D 65 72 61 20 62 79 20 63 68 61 72 o camera by char | |||
0016FF70 20 69 64 00 70 72 69 6E 74 73 20 66 72 61 67 73 id.prints frags | |||
0016FF80 20 61 6E 64 20 64 61 6D 61 67 65 20 63 6F 75 6E and damage coun | |||
0016FF90 74 65 72 00 63 72 65 61 74 65 73 20 63 6F 72 70 ter.creates corp | |||
0016FFA0 73 65 20 66 69 6C 65 20 66 72 6F 6D 20 70 6C 61 se file from pla | |||
0016FFB0 79 65 72 00 73 65 74 73 20 68 6F 72 69 7A 6F 6E yer.sets horizon | |||
0016FFC0 74 61 6C 20 66 69 65 6C 64 20 6F 66 20 76 69 65 tal field of vie | |||
0016FFD0 77 20 69 6E 20 64 65 67 72 65 65 73 00 73 65 74 w in degrees.set | |||
0016FFE0 73 20 68 65 61 6C 74 68 20 62 79 20 63 68 61 72 s health by char | |||
0016FFF0 20 69 64 00 73 65 74 73 20 4F 4E 43 43 20 66 6F id.sets ONCC fo | |||
00170000 72 20 67 69 76 65 6E 20 63 68 61 72 61 63 74 65 r given characte | |||
00170010 72 20 62 79 20 6E 61 6D 65 20 6F 72 20 69 64 00 r by name or id. | |||
00170020 74 72 61 6E 73 66 65 72 73 20 63 61 6D 65 72 61 transfers camera | |||
00170030 20 66 6F 63 75 73 20 61 6E 64 20 70 6C 61 79 65 focus and playe | |||
00170040 72 20 63 6F 6E 74 72 6F 6C 00 72 65 73 65 74 73 r control.resets | |||
00170050 20 70 6F 77 65 72 75 70 73 20 66 72 6F 6D 20 50 powerups from P | |||
00170060 57 52 55 00 72 65 73 65 74 73 20 63 6F 72 70 73 WRU.resets corps | |||
00170070 65 73 20 66 72 6F 6D 20 43 52 53 41 00 72 65 73 es from CRSA.res | |||
00170080 65 74 73 20 77 65 61 70 6F 6E 73 20 66 72 6F 6D ets weapons from | |||
00170090 20 57 45 41 50 00 63 68 72 5F 77 65 61 70 6F 6E WEAP.chr_weapon | |||
001700A0 00 63 68 72 5F 6C 6F 63 61 74 69 6F 6E 5F 73 65 .chr_location_se | |||
001700B0 74 74 6F 63 61 6D 65 72 61 00 63 68 72 5F 64 69 ttocamera.chr_di | |||
001700C0 73 70 6C 61 79 5F 63 6F 6D 62 61 74 5F 73 74 61 splay_combat_sta | |||
001700D0 74 73 00 6D 61 6B 65 5F 63 6F 72 70 73 65 00 6E ts.make_corpse.n | |||
001700E0 61 6D 65 3A 73 74 72 69 6E 67 00 67 73 5F 66 6F ame:string.gs_fo | |||
001700F0 76 5F 73 65 74 00 66 6F 76 3A 66 6C 6F 61 74 00 v_set.fov:float. | |||
00170100 63 68 72 5F 68 65 61 6C 74 68 00 63 68 72 5F 69 chr_health.chr_i | |||
00170110 64 20 5B 68 70 3A 69 6E 74 20 7C 20 5D 00 63 68 d [hp:int | ].ch | |||
00170120 72 5F 73 65 74 5F 63 6C 61 73 73 00 63 68 72 5F r_set_class.chr_ | |||
00170130 69 64 3A 69 6E 74 20 5B 63 6C 61 73 73 5F 6E 61 id:int [class_na | |||
00170140 6D 65 20 7C 20 63 6C 61 73 73 5F 69 64 3A 69 6E me | class_id:in | |||
00170150 74 5D 00 63 68 72 5F 66 6F 63 75 73 00 63 68 72 t].chr_focus.chr | |||
00170160 5F 69 64 3A 69 6E 74 00 70 6F 77 65 72 75 70 5F _id:int.powerup_ | |||
00170170 72 65 73 65 74 00 63 6F 72 70 73 65 5F 72 65 73 reset.corpse_res | |||
00170180 65 74 00 77 65 61 70 6F 6E 5F 72 65 73 65 74 00 et.weapon_reset. | |||
---- | |||
==BSL variables== | ==BSL variables== | ||
:: | :''Unsolved as of 06:39, 22 October 2008 (CEST). Needs a trimmed list of necessary PC vars matched with disposable Mac vars. | ||
Since sc_bind_f2 and sc_bind_f3 won't work, the OTA needs to be rewritten whatever we do. Probably waiting for special anims should be replaced with waiting for hotkeyed variables like fast_mode (Ctrl+Shift/Alt+F), draw_every_frame (Ctrl+Shift/Alt+G), or gs_show_performance (Ctrl+Shift/Alt+Y). If this is done in the randomizer loop, there will actually be fewer contexts pushed than in the current version. There will also be no counterintuitive keypress sequences (F9,F2,F10), no spurious FILM files and no risk of buffer overflow. --[[User:Geyser|geyser]] 06:39, 22 October 2008 (CEST) | |||
:: Can you give a script example of waiting for hotkeyed variables? I would like to test it out. Thanks [[User:EdT|EdT]] 20:45, 28 October 2008 (CET) | |||
===Preset Mac variables=== | |||
2+3+1+39=45 registered through tables ^_^ | |||
:16 variables registered elsewhere -_- | |||
;Missing (pointer to string can't be found) | |||
#p3_debug_collision (disposable) | |||
#p3_everything_breakable (...) | |||
#p3_furniture_breakable (cheatable) | |||
#p3_glass_breakable (disposable?) | |||
#p3_show_env_collision (disposable) | |||
;Quite disposable, but missing too -_- | |||
#ph_active | |||
#ph_debug_keyforces | |||
#ph_show_collisions | |||
;Also missing | |||
#sound_show_debug (pity; it's quite disposable) | |||
#wp_disable_fade (this one is useful anyway) | |||
#ui_suppress_prompt (useful too) | |||
;OpenGL initialisation (useful, missing) | |||
#gl_fog_blue | |||
#gl_fog_end | |||
#gl_fog_green | |||
#gl_fog_red | |||
#gl_fog_start | |||
;Table of boolean vars at 0x1BA2AC | |||
#marketing_line_off (used) | |||
#chr_big_head (used) | |||
;Table of boolean vars at 0x1BAC00 | |||
#invincible (used) | |||
#omnipotent (used) | |||
#unstoppable | |||
;Table of integer vars at 0x1BAC00 | |||
#save_point | |||
;Table at 0x0x1B9C54 | |||
#ai2_showpaths | |||
#ai2_showgrids | |||
#ai2_showdynamicgrids | |||
#ai2_showpathfindingerrors | |||
#ai2_showconnections | |||
#ai2_showactivationpaths | |||
#ai2_showastar | |||
#ai2_showcombatranges | |||
#ai2_showvision | |||
#ai2_showprediction | |||
#ai2_showtargeting | |||
#ai2_showlasers | |||
#ai2_showlos | |||
#ai2_showprojectiles | |||
#ai2_showfiringspreads | |||
#ai2_showlocalmelee | |||
#ai2_showfights | |||
#ai2_shownames | |||
#ai2_showhealth | |||
#ai2_showjoblocations | |||
#ai2_showlinetochar | |||
#ai2_showsounds | |||
#ai2_printspawn | |||
#ai2_blind | |||
#ai2_deaf | |||
#ai2_ignore_player | |||
#ai2_chump_stop | |||
#ai2_stopignoring_count | |||
#ai2_stopignoring_time | |||
#ai2_melee_weightcorrection | |||
#ai2_spacing_enable | |||
#ai2_spacing_cookies | |||
#ai2_spacing_weights | |||
#ai2_barabbas_run | |||
#ai2_boss_battle | |||
#ai2_showintersections | |||
#ai2_debug_localmovement | |||
#ai2_debug_localpathfinding | |||
#ai2_debug_showsettingIDs | |||
===Wishlist=== | |||
:Trying to list necessary variables off the top of my head (omitting sc_bind_f2 and sc_bind_f3, which won't work): --[[User:Geyser|geyser]] 06:39, 22 October 2008 (CEST) | |||
#co_display (to run stuff in dev mode without cluttering up the screen with debug messages all the time) | |||
#fast_mode (Ctrl+Shift/Alt+F) | |||
#draw_every_frame (Ctrl+Shift/Alt+G) | |||
#show_performance (Ctrl+Shift/Alt+Y) | |||
#li_center_cursor (to reclaim -noswitch; not sure it can be done) | |||
#chr_pin_character | |||
;Camera management | |||
#cm_distance | |||
#cm_height | |||
#cm_canter_weapon | |||
#cm_canter_unarmed | |||
#wp_scale_adjustment | |||
;Gameplay tweaking | |||
#chr_aim_width | |||
#chr_auto_aim_arc | |||
#chr_auto_aim_dist | |||
#chr_block_angle | |||
#chr_disable_melee | |||
#chr_weapon_auto_aim | |||
;Advanced stuff | |||
#chr_all_active | |||
#chr_disable_visactive | |||
#chr_draw_all_characters (pbly redundant of chr_all_active for the needs of OTA etc) | |||
#chr_lod (do we really need this?) | |||
#door_ignore_locks | |||
#gs_input_accel | |||
#gs_show_corpses | |||
#single_step (probably not needed; the hotkeys are enough) | |||
;Goofy | |||
#chr_big_head_amount | |||
#chr_mini_me | |||
#chr_mini_me_amount | |||
#wp_kickable | |||
#fx_laser_width | |||
#m3_fill_solid | |||
#m3_shade_vertex | |||
#gs_show_environment | |||
That's 33, which is a lot. 25 if we kick out the goofy. 24 if li_center_cursor doesn't work. | |||
===Brainstorming=== | |||
Below are two little tables and two big ones. The first table is variables that don't seem to work but probably do, with the special case of '''ai2_boss_battle''' beilng used in [compound]. Then there's a small table of "huh" variables that are almost certainly disposable. Then there are tables (mutually exclusive, but overlapping with the small ones): debug/display things (32 items) and not-likely-to-be-tweaked things (17 items). Those would disempower modders and hackers but wouldn't change much or anything for level logic. 49 variables is a lot, but we have to choose wisely, and may end up having to maintain two versions of the Mac engine, one with debug stuff, the other with stuff that is meant to be used in scripts. --[[User:Geyser|geyser]] 05:14, 10 October 2008 (CEST) | |||
:I'll start testing the variables and those I find that do not have a visible effect, I'll add to the possibly broken and disposable section. [[User:EdT|EdT]] 07:08, 10 October 2008 (CEST) | :I'll start testing the variables and those I find that do not have a visible effect, I'll add to the possibly broken and disposable section. [[User:EdT|EdT]] 07:08, 10 October 2008 (CEST) | ||
::Is it possible to add '''gs_show_ui'''? That would be useful when taking screenshots or videos without the HUD. I can maintain 2 versions of the Mac Engine, I think a very small number would need the debug features, but having more PC compatible commands will be more appealing since Mac users will be able to play more scripts. Plus it will make it easier for the script writers since there one script fits all! [[User:EdT|EdT]] 21:53, 10 October 2008 (CEST) | ::Is it possible to add '''gs_show_ui'''? That would be useful when taking screenshots or videos without the HUD. I can maintain 2 versions of the Mac Engine, I think a very small number would need the debug features, but having more PC compatible commands will be more appealing since Mac users will be able to play more scripts. Plus it will make it easier for the script writers since there one script fits all! [[User:EdT|EdT]] 21:53, 10 October 2008 (CEST) | ||
Line 405: | Line 814: | ||
:::I'll probably change wp_kickable to something else. wp_kickable allows the AI's to kick or move the weapon that's on the ground, but Konoko or the player cannot. [[User:EdT|EdT]] | :::I'll probably change wp_kickable to something else. wp_kickable allows the AI's to kick or move the weapon that's on the ground, but Konoko or the player cannot. [[User:EdT|EdT]] | ||
---- | ---- | ||
{{Table}} | {{Table}} | ||
|+BSL variables available on the Mac that have no visible effect but are not likely to be broken, either | |+BSL variables available on the Mac that have no visible effect but are not likely to be broken, either | ||
Line 447: | Line 853: | ||
{{Table}} | {{Table}} | ||
|+BSL variables available on the Mac that enable debug display | |+BSL variables available on the Mac that enable debug display | ||
|bool ai2_debug_localmovement||... | |||
|- | |- | ||
|bool ai2_debug_localpathfinding=0||"debug local-path code from player's position and facing" | |bool ai2_debug_localpathfinding=0||"debug local-path code from player's position and facing" | ||
Line 510: | Line 917: | ||
|bool sound_show_debug=0||"displays sound debugging info" | |bool sound_show_debug=0||"displays sound debugging info" | ||
|} | |} | ||
That's 32!!! ^_^ however, the last 5 are not registered in the common table, so we actually have access to 25 vars: enough to accomodate everything except the goofy. | |||
Line 516: | Line 924: | ||
|bool ai2_barabbas_run=1||"lets Barabbas run while carrying his gun" (disposable if we never need 0) | |bool ai2_barabbas_run=1||"lets Barabbas run while carrying his gun" (disposable if we never need 0) | ||
|- | |- | ||
|bool ai2_blind=0||"turns off the AI's visual sensing system" (disposable if we never need blind AI) | |bool ai2_blind=0||"turns off the AI's visual sensing system" (disposable if we never need blind AI; they can still be made blind individually) | ||
|- | |- | ||
|bool ai2_chump_stop=0||"stops the chump" | |bool ai2_chump_stop=0||"stops the chump" (disposable since we scrapped ai2_chump anyway) | ||
|- | |- | ||
|bool ai2_deaf=0||"turns off the AI's sound sensing system" (disposable if we never need deaf AI | |bool ai2_deaf=0||"turns off the AI's sound sensing system" (disposable if we never need deaf AI; they can still be made deaf individually) | ||
|- | |- | ||
|bool ai2_melee_weightcorrection=1||"weights down non-attack techniques so they are never more than attacks" (no visible effect) | |bool ai2_melee_weightcorrection=1||"weights down non-attack techniques so they are never more than attacks" (no visible effect) | ||
Line 548: | Line 954: | ||
|bool ph_debug_keyforces=0||"toggle keyboard applied forces" (no visible effect) | |bool ph_debug_keyforces=0||"toggle keyboard applied forces" (no visible effect) | ||
|} | |} | ||
That's 16, but the last 6 can't be used (marketing_line_off is used and the other 5 are "registered elsewhere"). So, 10. | |||
== | ===Summary=== | ||
: | All in all, we apparently have a maximum of 35 disposable variables, and a total of 31 on the wishlist. My suggestion: | ||
:If li_center_cursor works, leave these 4: ai2_spacing_cookies, ai2_spacing_enable, ai2_spacing_weights, ai2_barabbas_run. | |||
:If li_center_cursor doesn't work, leave these 5: ai2_melee_weightcorrection, ai2_spacing_cookies, ai2_spacing_enable, ai2_spacing_weights, ai2_barabbas_run. | |||
:Maybe don't keep anything and add 4 or 5 extras instead, like draw_every_frame_multiple, gs_screen_shot_reduce... | |||
Convert stuff "en masse" (there will be large contiguous blocks in the table, and in the name/description pool as well, although less so). | |||
The 3 blocks are as follows: | |||
#ai2_showpaths | |||
#ai2_showgrids | |||
#ai2_showdynamicgrids | |||
#ai2_showpathfindingerrors | |||
#ai2_showconnections | |||
#ai2_showactivationpaths | |||
#ai2_showastar | |||
#ai2_showcombatranges | |||
#ai2_showvision | |||
#ai2_showprediction | |||
#ai2_showtargeting | |||
#ai2_showlasers | |||
#ai2_showlos | |||
#ai2_showprojectiles | |||
#ai2_showfiringspreads | |||
#ai2_showlocalmelee | |||
#ai2_showfights | |||
#ai2_shownames | |||
#ai2_showhealth | |||
#ai2_showjoblocations | |||
#ai2_showlinetochar | |||
#ai2_showsounds | |||
#ai2_printspawn | |||
#ai2_blind | |||
#ai2_deaf | |||
#KEEP DEFINITELY | |||
#ai2_chump_stop | |||
#ai2_stopignoring_count | |||
#ai2_stopignoring_time | |||
#ai2_melee_weightcorrection (keep if no extras and li_center_cursor doesn't work) | |||
#ai2_spacing_enable (keep if no extras) | |||
#ai2_spacing_cookies (keep if no extras) | |||
#ai2_spacing_weights (keep if no extras) | |||
#ai2_barabbas_run (keep if no extras) | |||
#KEEP DEFINITELY | |||
#ai2_showintersections | |||
#ai2_debug_localmovement | |||
#ai2_debug_localpathfinding | |||
#ai2_debug_showsettingIDs | |||
(this does not necessarily correspond to contiguous strings) | |||
And our wishlist is like this: | |||
#co_display | |||
#fast_mode | |||
#draw_every_frame | |||
#show_performance | |||
#li_center_cursor | |||
#chr_pin_character | |||
#cm_distance | |||
#cm_height | |||
#cm_canter_weapon | |||
#cm_canter_unarmed | |||
#wp_scale_adjustment | |||
#chr_aim_width | |||
#chr_auto_aim_arc | |||
#chr_auto_aim_dist | |||
#chr_block_angle | |||
#chr_disable_melee | |||
#chr_weapon_auto_aim | |||
#chr_all_active | |||
#chr_disable_visactive | |||
#chr_draw_all_characters | |||
#chr_lod | |||
#door_ignore_locks | |||
#gs_input_accel | |||
#gs_show_corpses | |||
#single_step | |||
#chr_big_head_amount | |||
#chr_mini_me | |||
#chr_mini_me_amount | |||
#wp_kickable | |||
#fx_laser_width | |||
#m3_fill_solid | |||
#m3_shade_vertex | |||
#gs_show_environment | |||
33, to which we can add 4 or 5 extras like draw_every_frame_multiple, gs_screen_shot_reduce... | |||
:My impression is that there's plenty of space to accomodate all that. So let's do it. | |||
::[[User:Geyser|geyser]] 07:35, 22 October 2008 (CEST) | |||
[[Category:Patches]] | |||
Latest revision as of 01:39, 4 May 2022
Mac Daodan
- What's the possibility of making something Daodan-like for the Mac, or placing function calls in code caves? --rossy 11:18, 10 October 2008 (CEST)
- Define "code caves"; I'm not sure there's many of those, and we can't go very far with a hackish approach anyway. As for DLL-similar stuff, SFeLi said it was feasible and even relatively easy with Mach-O files: I haven't looked into that myself. --geyser 18:06, 10 October 2008 (CEST)
- Code caves? There are a ton of those in the Mac executable :) Neo
- wikt:code_cave Sounds neat\useful, for someone who is good at asm.Gumby 05:38, 16 October 2008 (CEST)
- Code caves? There are a ton of those in the Mac executable :) Neo
Uppercase letters at the console
- Issue still unsolved as of 06:39, 22 October 2008 (CEST)
Hmm, about the Shift key not being 'accessible'... I actually never noticed before that one cannot type capital letters on the command line, and if I did notice it I would have assumed the PC version was the same. So, one point and one question:
- It's not exactly true that the Shift key is not accessible or not recognized, because I can type important characters like the underscore and parentheses. It's merely that uppercase letters cannot be typed.
- Is the lack of access to uppercase letters an issue? This is total news to me, so naturally I am curious as to whether this has been a problem on the Mac side of things that I never knew about. --Iritscen 03:04, 7 October 2008 (CEST)
- The PC command line has no major issues: uppercase letters can be entered both on PC and PC demo. There are occasional glitches with autocompletion and some inconsistencies with multithreading (i.e., "fork"ing may not work as expected when launched from the console). Also, the command line is not displayed properly or at all at large resolutions.
- Thanks for the disambiguation about the Shift key. Ed didn't make it clear how exactly it didn't work. Do you confirm that the only characters that can't be entered are uppercase letters? Also, Ed, how long have your 3 "known issues" been around? Right from the moment when the Dev Mode was unlocked?
- The original variables and functions (preset of scripted) are all lowercase, but team names are capitalized, and many AI names contain uppercase letters as well. So lowercase-only input can be frustrating. The obvious workaround is to use scripts more, so that all command line statements can be lowercase.
- geyser 03:36, 7 October 2008 (CEST)
- Just confirmed it to make sure; only a-z cannot be modified by the Shift key, i.e., become uppercase. All other characters that require Shift can be typed. And thanks for the answer on what uses uppercase, the team names and AI names slipped my mind. I tested that as well, hoping that the Mac would ignore case, but alas; the console indeed does not recognize any team names without the uppercase letters. --Iritscen 04:02, 7 October 2008 (CEST)
- Also, I now see that capitals are required to type in animation names, therefore the chr_animate command is essentially unuseable on the Mac Oni console line; however, the command still works from within a BSL script, where caps are recognized. --iritscen 06:01, 7 November 2008 (CET)
- Iritscen, you beat me to it. The SHIFT key does not work in Dev Mode to enter uppercase letters (I should have been more specific, sorry). How long have I've known these issues? The SHIFT key problem was discovered when you, (geyser) asked me to enter some code in the console, I forgot when that happened. The Window mode issue was known as soon as it was figured out how to run Omni group's version in a window. I'm sure this was mentioned at some point, either here or at OCF. The problems with the Numpad key was known back in Jan 2007 and you suggested using the key_config.txt file EdT 04:11, 7 October 2008 (CEST)
- geyser 03:36, 7 October 2008 (CEST)
Large textures
The crash report is now history, but let's clarify the status of the patch at 0x001151C3. Is it irrelevant and can it be reverted?
- 0x001151C3 needs to be changed to 0x40 for 1024 textures, reverting to 0x04 or 0x10 results in crashes. Fortunately, I had already changed it to 0x40 prior to the latest patch.EdT 07:17, 22 October 2008 (CEST)
Projectile awareness
Fixed as of Dec 18 2008
|
BSL functions
Cleaning up previous talk, see history if you need reference
- Redeeming cm_barabus, because it looks like it works after all, and could be useful to both scripters and video makers (basically it interpolates the camera until it focuses on a certain character). So, Ed, please revert it.
- Scrapping all 11 ai2_skill_* functions, because their table entries and strings are conveniently grouped. Putting 11 "essentials" there. If you want to tweak shooting skills, use another version ^_^
- Keeping chr_holdkey as chr_location for now; may move it around later ^_^
- Turning ai2_panic into equally useless chr_draw_dot; we may change it later ^_^
- Turning ai2_chump into modder-oriented chr_who; we may change it later ^_^
- Turning ai2_printbnvindex into ui_fill_element; we may change it later ^_^
- For the big continuous patch you probably don't want to go nuts doing it byte by byte like I did, so grab a patched engine HERE and copy the relevant sections over to your backup. I used the big table below to proofread the patch, and we may still need it to check function pointers etc if something doesn't work.
Offset | Old hex | New hex | Description |
---|---|---|---|
0x1B9BDC | 00 17 1A 40 | 00 17 1A 40 | pointer to BSL name; unchanged |
0x1B9BE8 | 00 17 1A 54 | 00 17 1A 54 | pointer to help string; unchanged |
0x1B9BEC | 00 16 A1 48 | 00 17 86 20 | pointer to signature string; redirected |
0x1B9BF0 | 00 03 27 DC | 00 07 19 DC | pointer to function; now pointing to _ONiInGameUI_FillElement |
Offset | Old hex | New hex | Description |
---|---|---|---|
0x1B918C | 00 16 EE 24 | 00 16 EE 23 | pointer to BSL name; shifting 1 char backwards |
0x1B9198 | 00 16 FB E8 | 00 16 FB E8 | pointer to help string; unchanged |
0x1B919C | 00 16 FC 20 | 00 16 FC 20 | pointer to signature string; unchanged |
0x1B91A0 | 00 03 45 A8 | 00 04 17 20 | pointer to function; now pointing to _iSetAnyCharacterLocation |
Offset | Old hex | New hex | Description |
---|---|---|---|
0x1B9BF4 | 00 17 1A 7C | 00 17 1A 7C | pointer to BSL name; unchanged |
0x1B9C00 | 00 17 1A 88 | 00 17 1A 88 | pointer to help string; unchanged |
0x1B9C04 | 00 16 A1 48 | 00 16 A1 48 | pointer to signature string; unchanged |
0x1B9C08 | 00 03 2E E0 | 00 04 00 88 | pointer to function; now pointing to _ONrWho |
Offset | Old hex | New hex | Description |
---|---|---|---|
0x1B95DC | 00 16 F2 EC | 00 16 F2 EA | pointer to BSL name; shifting 2 chars backwards |
0x1B95E8 | 00 17 09 48 | 00 17 09 48 | pointer to help string; unchanged |
0x1B95EC | 00 17 09 68 | 00 17 09 68 | pointer to signature string; unchanged |
0x1B95F0 | 00 03 55 F8 | 00 04 15 04 | pointer to function; now pointing to _iDrawDot |
Offset | 0x170A40 | 0x170A54 |
---|---|---|
Old chars | ai2_printbnvindex°°° | prints the index of the player's BNV°°°° |
New chars | ui_fill_element°°°°° | forces a part of the UI to appear full°° |
Description | replacing name in_place | replacing help string in-place |
Offset | 0x16DE23 | 0x16EBE8 | 0x16EC20 |
---|---|---|---|
Old chars | °chr_holdkey° | forces a character to hold a key down for some frames°°° | [ai_name:string | script_id:int] key_name:string num_frames:int° |
New chars | chr_location° | sets location of a character or prints current location° | chr_index:int [[loc_x:float loc_y:float loc_z:float] | ]°°°°°°°° |
Description | replacing/shifting name | replacing help string in-place | replacing signature string in-place |
Offset | 0x170A7C | 0x170A88 |
---|---|---|
Old chars | ai2_chump° | creates a chump° |
New chars | chr_who°°° | lists all chars° |
Description | replacing name in-place | replacing help string in-place |
Offset | 0x16E2EA | 0x16F948 | 0x16F968 |
---|---|---|---|
Old chars | °°ai2_panic°°° | makes an AI panic or not panic°° | [ai_name:string | script_id:int] timer:int°° |
New chars | chr_draw_dot°° | draw line from player to point°° | [[loc_x:float loc_y:float loc_z:float] | ]°° |
Description | replacing/shifting name | replacing help string in-place | replacing signature string in-place |
Offset | Old hex | New hex | Description |
---|---|---|---|
0x1B975C | 00 17 0E 24 | 00 17 11 53 | pointer to BSL name chr_focus |
0x1B9768 | 00 17 0E 38 | 00 17 10 20 | pointer to help string |
0x1B976C | 00 17 0E 5C | 00 17 11 5D | pointer to signature string |
0x1B9770 | 00 03 0A 14 | 00 04 19 6C | pointer to function; now pointing to _SetMainCharacter |
0x1B9774 | 00 17 0E 84 | 00 17 11 68 | pointer to BSL name powerup_reset |
0x1B9780 | 00 17 0E 94 | 00 17 10 4A | pointer to help string |
0x1B9784 | 00 16 A1 48 | 00 16 A1 48 | pointer to signature string; unchanged |
0x1B9788 | 00 03 0B 60 | 00 0A 57 8C | pointer to function; now pointing to _WPiPowerups_Reset |
0x1B978C | 00 17 0E C0 | 00 17 11 76 | pointer to BSL name corpse_reset |
0x1B9798 | 00 17 0E D4 | 00 17 10 64 | pointer to help string |
0x1B979C | 00 16 A1 48 | 00 16 A1 48 | pointer to signature string; unchanged |
0x1B97A0 | 00 03 0C DC | 00 04 08 A0 | pointer to function; now pointing to _ONrCorpse_Reset |
0x1B97A4 | 00 17 0F 10 | 00 17 11 83 | pointer to BSL name weapon_reset |
0x1B97B0 | 00 17 0F 20 | 00 17 10 7D | pointer to help string |
0x1B97B4 | 00 16 A1 48 | 00 16 A1 48 | pointer to signature string; unchanged |
0x1B97B8 | 00 03 0D 90 | 00 0A 56 38 | pointer to function; now pointing to _WPiWeapons_Reset |
0x1B97BC | 00 17 0F 5C | 00 17 11 1E | pointer to BSL name chr_set_class |
0x1B97C8 | 00 17 0F 70 | 00 17 0F F4 | pointer to help string |
0x1B97CC | 00 17 0F A0 | 00 17 11 2C | pointer to signature string |
0x1B97D0 | 00 03 0F C0 | 00 04 06 14 | pointer to function; now pointing to _iSetCharacterClass |
0x1B97D4 | 00 17 0F BC | 00 17 11 00 | pointer to BSL name chr_health |
0x1B97E0 | 00 17 0F D0 | 00 17 0F DD | pointer to help string |
0x1B97E4 | 00 17 0F FC | 00 17 11 0B | pointer to signature string |
0x1B97E8 | 00 03 10 4C | 00 04 18 48 | pointer to function; now pointing to _iSetAnyCharacterHealth |
0x1B97EC | 00 17 10 10 | 00 17 10 EB | pointer to BSL name gs_fov_set |
0x1B97F8 | 00 17 10 20 | 00 17 0F B4 | pointer to help string |
0x1B97FC | 00 17 10 3C | 00 17 10 F6 | pointer to signature string |
0x1B9800 | 00 03 11 38 | 00 05 B8 18 | pointer to function; now pointing to _ONrGameState_FieldOfView_Set |
0x1B9804 | 00 17 10 50 | 00 17 10 D3 | pointer to BSL name make_corpse |
0x1B9810 | 00 17 10 60 | 00 17 0F 94 | pointer to help string |
0x1B9814 | 00 17 10 7C | 00 17 10 DF | pointer to signature string |
0x1B9818 | 00 03 11 C4 | 00 04 09 24 | pointer to function; now pointing to _ONrMakeCorpse |
0x1B981C | 00 17 10 90 | 00 17 10 BA | pointer to BSL name chr_display_combat_stats |
0x1B9828 | 00 17 10 A8 | 00 17 0F 74 | pointer to help string |
0x1B982C | 00 17 10 D4 | 00 17 11 5D | pointer to signature string |
0x1B9830 | 00 03 12 50 | 00 04 04 54 | pointer to function; now pointing to _iDiplayCharacterCombatStats |
0x1B9834 | 00 17 10 E8 | 00 17 10 A1 | pointer to BSL name chr_location_settocamera |
0x1B9840 | 00 17 10 FC | 00 17 0F 55 | pointer to help string |
0x1B9844 | 00 17 11 2C | 00 17 11 5D | pointer to signature string |
0x1B9848 | 00 03 12 DC | 00 04 1A AC | pointer to function; now pointing to _iCharacterLocation_SetFromCamera |
0x1B984C | 00 17 11 3C | 00 17 10 96 | pointer to BSL name chr_weapon |
0x1B9858 | 00 17 11 50 | 00 17 0F 29 | pointer to help string |
0x1B985C | 00 17 11 80 | 00 17 11 2C | pointer to signature string |
0x1B9860 | 00 03 13 84 | 00 04 19 E0 | pointer to function; now pointing to _iSetAnyCharacterWeapon |
- Replacing ai2_skill_* with eleven other funcs, leaving room for more strings
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F 001B9750 00 17 0E 24 ...$ 001B9760 00 00 00 00 00 00 00 00 00 17 0E 38 00 17 0E 5C ...........8...\ 001B9770 00 03 0A 14 00 17 0E 84 00 00 00 00 00 00 00 00 .......„........ 001B9780 00 17 0E 94 00 16 A1 48 00 03 0B 60 00 17 0E C0 ...”..¡H...`...À 001B9790 00 00 00 00 00 00 00 00 00 17 0E D4 00 16 A1 48 ...........Ô..¡H 001B97A0 00 03 0C DC 00 17 0F 10 00 00 00 00 00 00 00 00 ...Ü............ 001B97B0 00 17 0F 20 00 16 A1 48 00 03 0D 90 00 17 0F 5C ... ..¡H.......\ 001B97C0 00 00 00 00 00 00 00 00 00 17 0F 70 00 17 0F A0 ...........p... 001B97D0 00 03 0F C0 00 17 0F BC 00 00 00 00 00 00 00 00 ...À...¼........ 001B97E0 00 17 0F D0 00 17 0F FC 00 03 10 4C 00 17 10 10 ...Ð...ü...L.... 001B97F0 00 00 00 00 00 00 00 00 00 17 10 20 00 17 10 3C ........... ...< 001B9800 00 03 11 38 00 17 10 50 00 00 00 00 00 00 00 00 ...8...P........ 001B9810 00 17 10 60 00 17 10 7C 00 03 11 C4 00 17 10 90 ...`...|...Ä.... 001B9820 00 00 00 00 00 00 00 00 00 17 10 A8 00 17 10 D4 ...........¨...Ô 001B9830 00 03 12 50 00 17 10 E8 00 00 00 00 00 00 00 00 ...P...è........ 001B9840 00 17 10 FC 00 17 11 2C 00 03 12 DC 00 17 11 3C ...ü...,...Ü...< 001B9850 00 00 00 00 00 00 00 00 00 17 11 50 00 17 11 80 ...........P...€ 001B9860 00 03 13 84 ...„
must be changed to
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F 001B9750 00 17 11 53 ...S 001B9760 00 00 00 00 00 00 00 00 00 17 10 20 00 17 11 5D ........... ...] 001B9770 00 04 19 6C 00 17 11 68 00 00 00 00 00 00 00 00 ...l...h........ 001B9780 00 17 10 4A 00 16 A1 48 00 0A 57 8C 00 17 11 76 ...J..¡H..WŒ...v 001B9790 00 00 00 00 00 00 00 00 00 17 10 64 00 16 A1 48 ...........d..¡H 001B97A0 00 04 08 A0 00 17 11 83 00 00 00 00 00 00 00 00 ... ...ƒ........ 001B97B0 00 17 10 7D 00 16 A1 48 00 0A 56 38 00 17 11 1E ...}..¡H..V8.... 001B97C0 00 00 00 00 00 00 00 00 00 17 0F F4 00 17 11 2C ...........ô..., 001B97D0 00 04 06 14 00 17 11 00 00 00 00 00 00 00 00 00 ................ 001B97E0 00 17 0F DD 00 17 11 0B 00 04 18 48 00 17 10 EB ...Ý.......H...ë 001B97F0 00 00 00 00 00 00 00 00 00 17 0F B4 00 17 10 F6 ...........´...ö 001B9800 00 05 B8 18 00 17 10 D3 00 00 00 00 00 00 00 00 ..¸....Ó........ 001B9810 00 17 0F 94 00 17 10 DF 00 04 09 24 00 17 10 BA ...”...ß...$...º 001B9820 00 00 00 00 00 00 00 00 00 17 0F 74 00 17 11 5D ...........t...] 001B9830 00 04 04 54 00 17 10 A1 00 00 00 00 00 00 00 00 ...T...¡........ 001B9840 00 17 0F 55 00 17 11 5D 00 04 1A AC 00 17 10 96 ...U...]...¬...– 001B9850 00 00 00 00 00 00 00 00 00 17 0F 29 00 17 11 2C ...........)..., 001B9860 00 04 19 E0 ...à
and
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F 0016FE20 00 00 61 69 32 5F 73 6B 69 6C 6C 5F 73 65 ..ai2_skill_se 0016FE30 6C 65 63 74 00 00 00 00 73 65 6C 65 63 74 73 20 lect....selects 0016FE40 61 20 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C a shooting skill 0016FE50 20 74 6F 20 65 64 69 74 00 00 00 00 63 68 61 72 to edit....char 0016FE60 5F 63 6C 61 73 73 3A 73 74 72 69 6E 67 20 77 65 _class:string we 0016FE70 61 70 6F 6E 5F 6E 61 6D 65 3A 73 74 72 69 6E 67 apon_name:string 0016FE80 00 00 00 00 61 69 32 5F 73 6B 69 6C 6C 5F 73 68 ....ai2_skill_sh 0016FE90 6F 77 00 00 73 68 6F 77 73 20 74 68 65 20 63 75 ow..shows the cu 0016FEA0 72 72 65 6E 74 6C 79 20 73 65 6C 65 63 74 65 64 rrently selected 0016FEB0 20 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C 00 shooting skill. 0016FEC0 61 69 32 5F 73 6B 69 6C 6C 5F 72 65 76 65 72 74 ai2_skill_revert 0016FED0 00 00 00 00 72 65 76 65 72 74 73 20 74 68 65 20 ....reverts the 0016FEE0 73 68 6F 6F 74 69 6E 67 20 73 6B 69 6C 6C 20 62 shooting skill b 0016FEF0 65 69 6E 67 20 65 64 69 74 65 64 20 74 6F 20 74 eing edited to t 0016FF00 68 65 20 73 61 76 65 64 20 63 6F 70 79 00 00 00 he saved copy... 0016FF10 61 69 32 5F 73 6B 69 6C 6C 5F 73 61 76 65 00 00 ai2_skill_save.. 0016FF20 73 61 76 65 73 20 74 68 65 20 73 68 6F 6F 74 69 saves the shooti 0016FF30 6E 67 20 73 6B 69 6C 6C 20 62 65 69 6E 67 20 65 ng skill being e 0016FF40 64 69 74 65 64 20 6F 75 74 20 61 73 20 61 20 74 dited out as a t 0016FF50 65 78 74 20 66 69 6C 65 00 00 00 00 61 69 32 5F ext file....ai2_ 0016FF60 73 6B 69 6C 6C 5F 72 65 63 6F 69 6C 00 00 00 00 skill_recoil.... 0016FF70 73 65 74 73 20 61 6E 20 41 49 27 73 20 72 65 63 sets an AI's rec 0016FF80 6F 69 6C 20 63 6F 6D 70 65 6E 73 61 74 69 6F 6E oil compensation 0016FF90 20 61 6D 6F 75 6E 74 20 28 30 2D 31 29 00 00 00 amount (0-1)... 0016FFA0 72 65 63 6F 69 6C 5F 63 6F 6D 70 65 6E 73 61 74 recoil_compensat 0016FFB0 69 6F 6E 3A 66 6C 6F 61 74 00 00 00 61 69 32 5F ion:float...ai2_ 0016FFC0 73 6B 69 6C 6C 5F 62 65 73 74 61 6E 67 6C 65 00 skill_bestangle. 0016FFD0 73 65 74 73 20 61 6E 20 41 49 27 73 20 62 65 73 sets an AI's bes 0016FFE0 74 20 61 69 6D 69 6E 67 20 61 6E 67 6C 65 20 69 t aiming angle i 0016FFF0 6E 20 64 65 67 72 65 65 73 00 00 00 62 65 73 74 n degrees...best 00170000 5F 61 6E 67 6C 65 3A 66 6C 6F 61 74 00 00 00 00 _angle:float.... 00170010 61 69 32 5F 73 6B 69 6C 6C 5F 65 72 72 6F 72 00 ai2_skill_error. 00170020 73 65 74 73 20 61 6E 20 41 49 27 73 20 67 72 6F sets an AI's gro 00170030 75 70 69 6E 67 20 65 72 72 6F 72 00 65 72 72 6F uping error.erro 00170040 72 5F 61 6D 6F 75 6E 74 3A 66 6C 6F 61 74 00 00 r_amount:float.. 00170050 61 69 32 5F 73 6B 69 6C 6C 5F 64 65 63 61 79 00 ai2_skill_decay. 00170060 73 65 74 73 20 61 6E 20 41 49 27 73 20 67 72 6F sets an AI's gro 00170070 75 70 69 6E 67 20 64 65 63 61 79 00 64 65 63 61 uping decay.deca 00170080 79 5F 61 6D 6F 75 6E 74 3A 66 6C 6F 61 74 00 00 y_amount:float.. 00170090 61 69 32 5F 73 6B 69 6C 6C 5F 69 6E 61 63 63 75 ai2_skill_inaccu 001700A0 72 61 63 79 00 00 00 00 73 65 74 73 20 61 6E 20 racy....sets an 001700B0 41 49 27 73 20 73 68 6F 6F 74 69 6E 67 20 69 6E AI's shooting in 001700C0 61 63 63 75 72 61 63 79 20 6D 75 6C 74 69 70 6C accuracy multipl 001700D0 69 65 72 00 69 6E 61 63 63 75 72 61 63 79 3A 66 ier.inaccuracy:f 001700E0 6C 6F 61 74 00 00 00 00 61 69 32 5F 73 6B 69 6C loat....ai2_skil 001700F0 6C 5F 64 65 6C 61 79 6D 69 6E 00 00 73 65 74 73 l_delaymin..sets 00170100 20 61 6E 20 41 49 27 73 20 6D 69 6E 20 64 65 6C an AI's min del 00170110 61 79 20 62 65 74 77 65 65 6E 20 73 68 6F 74 73 ay between shots 00170120 2C 20 69 6E 20 66 72 61 6D 65 73 00 6D 69 6E 64 , in frames.mind 00170130 65 6C 61 79 3A 69 6E 74 00 00 00 00 61 69 32 5F elay:int....ai2_ 00170140 73 6B 69 6C 6C 5F 64 65 6C 61 79 6D 61 78 00 00 skill_delaymax.. 00170150 73 65 74 73 20 61 6E 20 41 49 27 73 20 6D 61 78 sets an AI's max 00170160 20 64 65 6C 61 79 20 62 65 74 77 65 65 6E 20 73 delay between s 00170170 68 6F 74 73 2C 20 69 6E 20 66 72 61 6D 65 73 00 hots, in frames. 00170180 6D 61 78 64 65 6C 61 79 3A 69 6E 74 00 00 00 00 maxdelay:int....
must be changed to
Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F 0016FE20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 .............. 0016FE30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE50 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE60 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE70 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FE90 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FEA0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FEB0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FEC0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FED0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FEE0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FEF0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FF00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FF10 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0016FF20 00 00 00 00 00 00 00 00 00 73 65 74 73 20 4F 4E .........sets ON 0016FF30 57 43 20 66 6F 72 20 67 69 76 65 6E 20 63 68 61 WC for given cha 0016FF40 72 61 63 74 65 72 20 62 79 20 6E 61 6D 65 20 6F racter by name o 0016FF50 72 20 69 64 00 74 65 6C 65 70 6F 72 74 73 20 74 r id.teleports t 0016FF60 6F 20 63 61 6D 65 72 61 20 62 79 20 63 68 61 72 o camera by char 0016FF70 20 69 64 00 70 72 69 6E 74 73 20 66 72 61 67 73 id.prints frags 0016FF80 20 61 6E 64 20 64 61 6D 61 67 65 20 63 6F 75 6E and damage coun 0016FF90 74 65 72 00 63 72 65 61 74 65 73 20 63 6F 72 70 ter.creates corp 0016FFA0 73 65 20 66 69 6C 65 20 66 72 6F 6D 20 70 6C 61 se file from pla 0016FFB0 79 65 72 00 73 65 74 73 20 68 6F 72 69 7A 6F 6E yer.sets horizon 0016FFC0 74 61 6C 20 66 69 65 6C 64 20 6F 66 20 76 69 65 tal field of vie 0016FFD0 77 20 69 6E 20 64 65 67 72 65 65 73 00 73 65 74 w in degrees.set 0016FFE0 73 20 68 65 61 6C 74 68 20 62 79 20 63 68 61 72 s health by char 0016FFF0 20 69 64 00 73 65 74 73 20 4F 4E 43 43 20 66 6F id.sets ONCC fo 00170000 72 20 67 69 76 65 6E 20 63 68 61 72 61 63 74 65 r given characte 00170010 72 20 62 79 20 6E 61 6D 65 20 6F 72 20 69 64 00 r by name or id. 00170020 74 72 61 6E 73 66 65 72 73 20 63 61 6D 65 72 61 transfers camera 00170030 20 66 6F 63 75 73 20 61 6E 64 20 70 6C 61 79 65 focus and playe 00170040 72 20 63 6F 6E 74 72 6F 6C 00 72 65 73 65 74 73 r control.resets 00170050 20 70 6F 77 65 72 75 70 73 20 66 72 6F 6D 20 50 powerups from P 00170060 57 52 55 00 72 65 73 65 74 73 20 63 6F 72 70 73 WRU.resets corps 00170070 65 73 20 66 72 6F 6D 20 43 52 53 41 00 72 65 73 es from CRSA.res 00170080 65 74 73 20 77 65 61 70 6F 6E 73 20 66 72 6F 6D ets weapons from 00170090 20 57 45 41 50 00 63 68 72 5F 77 65 61 70 6F 6E WEAP.chr_weapon 001700A0 00 63 68 72 5F 6C 6F 63 61 74 69 6F 6E 5F 73 65 .chr_location_se 001700B0 74 74 6F 63 61 6D 65 72 61 00 63 68 72 5F 64 69 ttocamera.chr_di 001700C0 73 70 6C 61 79 5F 63 6F 6D 62 61 74 5F 73 74 61 splay_combat_sta 001700D0 74 73 00 6D 61 6B 65 5F 63 6F 72 70 73 65 00 6E ts.make_corpse.n 001700E0 61 6D 65 3A 73 74 72 69 6E 67 00 67 73 5F 66 6F ame:string.gs_fo 001700F0 76 5F 73 65 74 00 66 6F 76 3A 66 6C 6F 61 74 00 v_set.fov:float. 00170100 63 68 72 5F 68 65 61 6C 74 68 00 63 68 72 5F 69 chr_health.chr_i 00170110 64 20 5B 68 70 3A 69 6E 74 20 7C 20 5D 00 63 68 d [hp:int | ].ch 00170120 72 5F 73 65 74 5F 63 6C 61 73 73 00 63 68 72 5F r_set_class.chr_ 00170130 69 64 3A 69 6E 74 20 5B 63 6C 61 73 73 5F 6E 61 id:int [class_na 00170140 6D 65 20 7C 20 63 6C 61 73 73 5F 69 64 3A 69 6E me | class_id:in 00170150 74 5D 00 63 68 72 5F 66 6F 63 75 73 00 63 68 72 t].chr_focus.chr 00170160 5F 69 64 3A 69 6E 74 00 70 6F 77 65 72 75 70 5F _id:int.powerup_ 00170170 72 65 73 65 74 00 63 6F 72 70 73 65 5F 72 65 73 reset.corpse_res 00170180 65 74 00 77 65 61 70 6F 6E 5F 72 65 73 65 74 00 et.weapon_reset.
BSL variables
- Unsolved as of 06:39, 22 October 2008 (CEST). Needs a trimmed list of necessary PC vars matched with disposable Mac vars.
Since sc_bind_f2 and sc_bind_f3 won't work, the OTA needs to be rewritten whatever we do. Probably waiting for special anims should be replaced with waiting for hotkeyed variables like fast_mode (Ctrl+Shift/Alt+F), draw_every_frame (Ctrl+Shift/Alt+G), or gs_show_performance (Ctrl+Shift/Alt+Y). If this is done in the randomizer loop, there will actually be fewer contexts pushed than in the current version. There will also be no counterintuitive keypress sequences (F9,F2,F10), no spurious FILM files and no risk of buffer overflow. --geyser 06:39, 22 October 2008 (CEST)
- Can you give a script example of waiting for hotkeyed variables? I would like to test it out. Thanks EdT 20:45, 28 October 2008 (CET)
Preset Mac variables
2+3+1+39=45 registered through tables ^_^
- 16 variables registered elsewhere -_-
- Missing (pointer to string can't be found)
- p3_debug_collision (disposable)
- p3_everything_breakable (...)
- p3_furniture_breakable (cheatable)
- p3_glass_breakable (disposable?)
- p3_show_env_collision (disposable)
- Quite disposable, but missing too -_-
- ph_active
- ph_debug_keyforces
- ph_show_collisions
- Also missing
- sound_show_debug (pity; it's quite disposable)
- wp_disable_fade (this one is useful anyway)
- ui_suppress_prompt (useful too)
- OpenGL initialisation (useful, missing)
- gl_fog_blue
- gl_fog_end
- gl_fog_green
- gl_fog_red
- gl_fog_start
- Table of boolean vars at 0x1BA2AC
- marketing_line_off (used)
- chr_big_head (used)
- Table of boolean vars at 0x1BAC00
- invincible (used)
- omnipotent (used)
- unstoppable
- Table of integer vars at 0x1BAC00
- save_point
- Table at 0x0x1B9C54
- ai2_showpaths
- ai2_showgrids
- ai2_showdynamicgrids
- ai2_showpathfindingerrors
- ai2_showconnections
- ai2_showactivationpaths
- ai2_showastar
- ai2_showcombatranges
- ai2_showvision
- ai2_showprediction
- ai2_showtargeting
- ai2_showlasers
- ai2_showlos
- ai2_showprojectiles
- ai2_showfiringspreads
- ai2_showlocalmelee
- ai2_showfights
- ai2_shownames
- ai2_showhealth
- ai2_showjoblocations
- ai2_showlinetochar
- ai2_showsounds
- ai2_printspawn
- ai2_blind
- ai2_deaf
- ai2_ignore_player
- ai2_chump_stop
- ai2_stopignoring_count
- ai2_stopignoring_time
- ai2_melee_weightcorrection
- ai2_spacing_enable
- ai2_spacing_cookies
- ai2_spacing_weights
- ai2_barabbas_run
- ai2_boss_battle
- ai2_showintersections
- ai2_debug_localmovement
- ai2_debug_localpathfinding
- ai2_debug_showsettingIDs
Wishlist
- Trying to list necessary variables off the top of my head (omitting sc_bind_f2 and sc_bind_f3, which won't work): --geyser 06:39, 22 October 2008 (CEST)
- co_display (to run stuff in dev mode without cluttering up the screen with debug messages all the time)
- fast_mode (Ctrl+Shift/Alt+F)
- draw_every_frame (Ctrl+Shift/Alt+G)
- show_performance (Ctrl+Shift/Alt+Y)
- li_center_cursor (to reclaim -noswitch; not sure it can be done)
- chr_pin_character
- Camera management
- cm_distance
- cm_height
- cm_canter_weapon
- cm_canter_unarmed
- wp_scale_adjustment
- Gameplay tweaking
- chr_aim_width
- chr_auto_aim_arc
- chr_auto_aim_dist
- chr_block_angle
- chr_disable_melee
- chr_weapon_auto_aim
- Advanced stuff
- chr_all_active
- chr_disable_visactive
- chr_draw_all_characters (pbly redundant of chr_all_active for the needs of OTA etc)
- chr_lod (do we really need this?)
- door_ignore_locks
- gs_input_accel
- gs_show_corpses
- single_step (probably not needed; the hotkeys are enough)
- Goofy
- chr_big_head_amount
- chr_mini_me
- chr_mini_me_amount
- wp_kickable
- fx_laser_width
- m3_fill_solid
- m3_shade_vertex
- gs_show_environment
That's 33, which is a lot. 25 if we kick out the goofy. 24 if li_center_cursor doesn't work.
Brainstorming
Below are two little tables and two big ones. The first table is variables that don't seem to work but probably do, with the special case of ai2_boss_battle beilng used in [compound]. Then there's a small table of "huh" variables that are almost certainly disposable. Then there are tables (mutually exclusive, but overlapping with the small ones): debug/display things (32 items) and not-likely-to-be-tweaked things (17 items). Those would disempower modders and hackers but wouldn't change much or anything for level logic. 49 variables is a lot, but we have to choose wisely, and may end up having to maintain two versions of the Mac engine, one with debug stuff, the other with stuff that is meant to be used in scripts. --geyser 05:14, 10 October 2008 (CEST)
- I'll start testing the variables and those I find that do not have a visible effect, I'll add to the possibly broken and disposable section. EdT 07:08, 10 October 2008 (CEST)
- Is it possible to add gs_show_ui? That would be useful when taking screenshots or videos without the HUD. I can maintain 2 versions of the Mac Engine, I think a very small number would need the debug features, but having more PC compatible commands will be more appealing since Mac users will be able to play more scripts. Plus it will make it easier for the script writers since there one script fits all! EdT 21:53, 10 October 2008 (CEST)
- Ed, you can use ui_show_element(left,0) and ui_show_element(right,0) instead of gs_show_ui=0; and don't forget ui_suppress_prompt=0 and such. The compatibility of scripts, of course, is the main goal. I just wanted to make sure you backed up the versions prior to those rewiring of mine because we are screwing with the engine in hackish ways and may want to take a few steps back. --geyser 02:01, 11 October 2008 (CEST)
- Thank you, I did not know about that command, that saves one variable :-) I seem to recall another PC command door_ignore_locks used in some script, this might be useful... EdT 05:40, 11 October 2008 (CEST)
- According to Neo sc_bind_f2, sc_bind_f3 cannot be added because the are strings and neither can gs_fov_set be added. However, he was able to add co_display and door_ignore_locks EdT 00:38, 16 October 2008 (CEST)
- He was able to add them? So he gave you the fish after all? ^_^ If you want to allow me to give you more fish this week-end, please document the new fish in more detail, so that I know what disposable variables I can no longer use. As for gs_fov_set, it's a pity, gonna ask Neo what's the matter with it. --geyser 01:18, 16 October 2008 (CEST)
- According to Neo sc_bind_f2, sc_bind_f3 cannot be added because the are strings and neither can gs_fov_set be added. However, he was able to add co_display and door_ignore_locks EdT 00:38, 16 October 2008 (CEST)
- Thank you, I did not know about that command, that saves one variable :-) I seem to recall another PC command door_ignore_locks used in some script, this might be useful... EdT 05:40, 11 October 2008 (CEST)
- For Reference, Neo's changes
- co_display = _COgDisplayConsole
- name string: at 0x170E8C - REPLACE "ai2_showlos" with "co_display", 0
- var pointer: at 0x1B9D20 - REPLACE 0x0018EDD4 with 0x00193579
- door_ignore_locks = _OBJgDoor_IgnoreLocks
- name string: at 0x171410 - REPLACE "ai2_showintersections" with "door_ignore_locks", 0
- var pointer: at 0x1B9E90 - REPLACE 0x00195D2C with 0x0027A1B9
- wp_kickable = _WPgPlayerKicksWeapons
- name string: at 0x171098 -REPLACE "ai2_showsounds" with "wp_kickable", 0
- var pointer: at 0x1B9DB0 - REPLACE 0x0018EDC2 with 0x00192B05
- EdT 04:29, 16 October 2008 (CEST)
- Just curious, why wp_kickable? I have tried, and I cannot figure out what is stopping Konoko from kicking weapons...Gumby 05:36, 16 October 2008 (CEST)
- I'll probably change wp_kickable to something else. wp_kickable allows the AI's to kick or move the weapon that's on the ground, but Konoko or the player cannot. EdT
- Just curious, why wp_kickable? I have tried, and I cannot figure out what is stopping Konoko from kicking weapons...Gumby 05:36, 16 October 2008 (CEST)
bool ai2_boss_battle=0 | "enables AI boss-battle target selection" |
bool ai2_melee_weightcorrection=1 | "weights down non-attack techniques so they are never more than attacks" |
int32 ai2_stopignoring_count=6 | "set the number of events before the AI will stop ignoring" |
int32 ai2_stopignoring_time=240 | "set the delay timer before the AI forgets about ignored events" |
bool ai2_debug_showsettingIDs=0 | "shows ID numbers for combat, melee and neutral settings" |
bool ai2_showastar=0 | "shows grid squares that are evaluated by the A* pathfinding" |
bool ai2_showintersections=0 | "debug AI's melee intersections" |
bool ai2_showlasers=0 | "turns on laser sights for AI2 characters" |
bool ph_debug_keyforces=0 | "toggle keyboard applied forces" |
int32 ai2_debug_localmove_lines=20 | "number of lines to cast to debug local-movement code" (needs ai2_debug_localmovement, which is missing) |
bool ai2_showlos=0 | "shows AI line-of-sight checking" |
bool ai2_shownames=0 | "draws the name of every AI above their head" |
bool ai2_showsounds=0 | "shows AI sounds as they are generated" |
bool ai2_debug_localmovement | ... |
bool ai2_debug_localpathfinding=0 | "debug local-path code from player's position and facing" |
bool ai2_debug_showsettingIDs=0 | "shows ID numbers for combat, melee and neutral settings" (no visible effect) |
bool ai2_printspawn=0 | "prints information about each AI spawn" |
bool ai2_showactivationpaths=0 | "turns on inactive ==> active pathfinding rendering" |
bool ai2_showastar=0 | "shows grid squares that are evaluated by the A* pathfinding" (no visible effect) |
bool ai2_showcombatranges=0 | "shows circles that represent the combat ranges of each AI" |
bool ai2_showconnections=0 | "turns on pathfinding connection rendering" |
bool ai2_showdynamicgrids=0 | "turns on pathfinding dynamic grid display" |
bool ai2_showfights=0 | "shows fights in progress" |
bool ai2_showfiringspreads=0 | "shows AI firing spread knowledge" |
bool ai2_showgrids=0 | "turns on pathfinding grid rendering" |
bool ai2_showhealth=0 | "draws a health bar for every AI above their head" |
bool ai2_showintersections=0 | "debug AI's melee intersections" (no visible effect) |
bool ai2_showjoblocations=0 | "draws a green cross at each AI's job location" |
bool ai2_showlasers=0 | "turns on laser sights for AI2 characters" (no visible effect) |
bool ai2_showlinetochar=0 | "draws a line from the player to every AI" |
bool ai2_showlocalmelee=0 | "shows local-environment melee awareness" |
bool ai2_showlos=0 | "shows AI line-of-sight checking" (no visible effect) |
bool ai2_shownames=0 | "draws the name of every AI above their head" (no visible effect) |
bool ai2_showpathfindingerrors=0 | "enables visual display of pathfinding errors" |
bool ai2_showpaths=0 | "shows the path each AI is following" |
bool ai2_showprediction=0 | "shows prediction info for AI2 characters" |
bool ai2_showprojectiles=0 | "shows AI projectile knowledge" |
bool ai2_showsounds=0 | "shows AI sounds as they are generated" (no visible effect) |
bool ai2_showtargeting=0 | "shows targeting info for AI2 characters" |
bool ai2_showvision=0 | "shows each AI's vision cones (central and peripheral)" |
int32 p3_debug_collision=256 | "enables collision debugging display" |
bool ph_debug_keyforces=0 | "toggle keyboard applied forces" (no visible effect) |
bool p3_show_env_collision=0 | "draws particle / environment collisions" |
bool ph_show_collisions=0 | "toggle display of colliding quads" |
bool sound_show_debug=0 | "displays sound debugging info" |
That's 32!!! ^_^ however, the last 5 are not registered in the common table, so we actually have access to 25 vars: enough to accomodate everything except the goofy.
bool ai2_barabbas_run=1 | "lets Barabbas run while carrying his gun" (disposable if we never need 0) |
bool ai2_blind=0 | "turns off the AI's visual sensing system" (disposable if we never need blind AI; they can still be made blind individually) |
bool ai2_chump_stop=0 | "stops the chump" (disposable since we scrapped ai2_chump anyway) |
bool ai2_deaf=0 | "turns off the AI's sound sensing system" (disposable if we never need deaf AI; they can still be made deaf individually) |
bool ai2_melee_weightcorrection=1 | "weights down non-attack techniques so they are never more than attacks" (no visible effect) |
int32 ai2_spacing_cookies=2 | "number of cookies per fight" |
bool ai2_spacing_enable=1 | "master enable switch for spacing behavior" |
bool ai2_spacing_weights=1 | "enables position-sensitive weighting of spacing behaviors" |
int32 ai2_stopignoring_count=6 | "set the number of events before the AI will stop ignoring" (no visible effect) |
int32 ai2_stopignoring_time=240 | "set the delay timer before the AI forgets about ignored events" (no visible effect) |
bool marketing_line_off=0 | "turns the laser line off" (player's laser sight, crosshair, etc) |
bool p3_everything_breakable=0 | "makes every quad breakable" |
bool p3_furniture_breakable=0 | "makes all furniture breakable" |
bool p3_glass_breakable=1 | "enables breakable glass" |
bool ph_active=1 | "enable physics" |
bool ph_debug_keyforces=0 | "toggle keyboard applied forces" (no visible effect) |
That's 16, but the last 6 can't be used (marketing_line_off is used and the other 5 are "registered elsewhere"). So, 10.
Summary
All in all, we apparently have a maximum of 35 disposable variables, and a total of 31 on the wishlist. My suggestion:
- If li_center_cursor works, leave these 4: ai2_spacing_cookies, ai2_spacing_enable, ai2_spacing_weights, ai2_barabbas_run.
- If li_center_cursor doesn't work, leave these 5: ai2_melee_weightcorrection, ai2_spacing_cookies, ai2_spacing_enable, ai2_spacing_weights, ai2_barabbas_run.
- Maybe don't keep anything and add 4 or 5 extras instead, like draw_every_frame_multiple, gs_screen_shot_reduce...
Convert stuff "en masse" (there will be large contiguous blocks in the table, and in the name/description pool as well, although less so).
The 3 blocks are as follows:
- ai2_showpaths
- ai2_showgrids
- ai2_showdynamicgrids
- ai2_showpathfindingerrors
- ai2_showconnections
- ai2_showactivationpaths
- ai2_showastar
- ai2_showcombatranges
- ai2_showvision
- ai2_showprediction
- ai2_showtargeting
- ai2_showlasers
- ai2_showlos
- ai2_showprojectiles
- ai2_showfiringspreads
- ai2_showlocalmelee
- ai2_showfights
- ai2_shownames
- ai2_showhealth
- ai2_showjoblocations
- ai2_showlinetochar
- ai2_showsounds
- ai2_printspawn
- ai2_blind
- ai2_deaf
- KEEP DEFINITELY
- ai2_chump_stop
- ai2_stopignoring_count
- ai2_stopignoring_time
- ai2_melee_weightcorrection (keep if no extras and li_center_cursor doesn't work)
- ai2_spacing_enable (keep if no extras)
- ai2_spacing_cookies (keep if no extras)
- ai2_spacing_weights (keep if no extras)
- ai2_barabbas_run (keep if no extras)
- KEEP DEFINITELY
- ai2_showintersections
- ai2_debug_localmovement
- ai2_debug_localpathfinding
- ai2_debug_showsettingIDs
(this does not necessarily correspond to contiguous strings)
And our wishlist is like this:
- co_display
- fast_mode
- draw_every_frame
- show_performance
- li_center_cursor
- chr_pin_character
- cm_distance
- cm_height
- cm_canter_weapon
- cm_canter_unarmed
- wp_scale_adjustment
- chr_aim_width
- chr_auto_aim_arc
- chr_auto_aim_dist
- chr_block_angle
- chr_disable_melee
- chr_weapon_auto_aim
- chr_all_active
- chr_disable_visactive
- chr_draw_all_characters
- chr_lod
- door_ignore_locks
- gs_input_accel
- gs_show_corpses
- single_step
- chr_big_head_amount
- chr_mini_me
- chr_mini_me_amount
- wp_kickable
- fx_laser_width
- m3_fill_solid
- m3_shade_vertex
- gs_show_environment
33, to which we can add 4 or 5 extras like draw_every_frame_multiple, gs_screen_shot_reduce...
- My impression is that there's plenty of space to accomodate all that. So let's do it.
- geyser 07:35, 22 October 2008 (CEST)