Random Number Generator

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search

Call the system RNG, which sets r2 = rand(0..7fff). See RNG.

0002230c: 240a00a0 addiu r10,r0,0x00a0
00022310: 01400008 jr r10               # Jump to 0xA0 (system call), with r9 = 0x2f (47). This calls the PSX RNG.
00022314: 2409002f addiu r9,r0,0x002f


Return Locations

  • SCUS
00059ffc: Out of Battle Unit Generation x2
0005a448: Generate Unit's Base Raw Stats
0005ac1c: ENTD Data Calculation
0005b500: Sprite Set and Random Secondary Job Calculation
0005ba70: Calculate Unit's Abilities
0005c984: Store/Generate Character Names
0005cc98: Calculate Random Equipment
0005d0bc: Calculate Unit's R/S/M
0005da10: Level Up Section
0005e0cc: Check if Random is greater/equal to Chance
  • Battle.bin
0008e724:
0008e754:
0008e9b4:
0008ea1c:
0008ebec:
0008eea0:
000e85f4:
000e8638:
000e92a8:
000e9464:
000e9478:
000e94ac:
000e9500:
000e9514:
000e9548:
000e958c:
000e95a0:
000e9600:
000e9614:
000e9a24:
000e9be0:
000e9bf4:
000e9c28:
000e9c84:
000e9c98:
000e9ccc:
000e9d10:
000e9d24:
000e9d84:
000e9d98:
000ea1d4:
000ea214:
000ea298:
000eefac:
000ef00c:
000ef180:
000ef194:
000ef1e8:
000ef234:
000ef248:
000ef290:
000ef318:
000ef340:
000ef368:
000ef3bc:
0017d604: Determining_Multi_Hit_Formulas
0017d784: Select_Random_Tile_For_Random_Fire_Abilities
0017f118:
0017fa34:
00180a7c: Generate_Treasure
00180ac8: Generate_Treasure
001830a0: Death_sentence,_crystalization,_treasurization,_etc
0018318c: Death_sentence,_crystalization,_treasurization,_etc
0018eebc: Random_Process,_gives_a_number_between_0-7fff
001966f4:
00197118:
001973fc:
001975b0:
001975e8:
00197678:
001976b8:
00197790:
00197bb0:
0019afb0:
0019eed4:
001a6724:
001a6748:
001a67a8:
001a67cc:
001a682c:
001a6850:
001a68e0:
001a68e8:
001a68f0:
001a6c4c:
001a6c70:
001a6cbc:
001a6ce0:
001a6d2c:
001a6d50:
001a6dbc:
001a6dd8:
001a6e98:
001a6ebc:
001a6f08:
001a6f2c:
001a6f78:
001a6f9c:
001a7008:
001a7024:
001a7150:
001a716c:
001a74b4:
001a74cc:
001a7514:
001a752c:
  • Wldcore.Bin
000706c4:
00070710:
0007330c:
00077f2c:
000796d0:
00079bfc:
00079f24:
00079f60:
00079f84:
0007a02c:
00080654:
00080690:
0008baf4:
0008f188:
0008f1e4:
  • World.Bin
00119eec:
00119f18:
00120508:
00120538:
00120564:
00125b98:
00125bc8: 
00125c0c:
00125c60:
00125ca8: