Adding Flags
Original author on Discord: @z_u_ra, modified by @n123original
NOTE: IN YOKAI WATCH 2, THIS CRASHES THE GAME DUE TO A BUG WITHIN THE ENGINE! Only use this guide in YW1, YW3, YWB1 OR YWB2
There are several types of flags with the most common type being GlobalBitFlags; these are boolean meaning they can be either a 1 (enabled/true) or a 0 (disabled/false); you can get/set these in XQ via get_global_bitflag() and set_global_bitflag(). Another common type is GlobalByteFlags which are 8-bit integers meaning they can be any number between 0 and 255.
Creating GlobalBitFlags
- Navigate over to
data/res/sys/ - There you will find a
flag_config.cfg.bin- open it.- If you see multiple, pick the one with the largest number i.e. if theres
flag_config.cfg.binandflag_config_0.01a.cfg.bin, pick the second option.
- If you see multiple, pick the one with the largest number i.e. if theres
- Click on
FLAG_INFO_0.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_0and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
Creating GlobalByteFlags
- Navigate over to
data/res/sys/ - There you will find a
flag_config.cfg.bin- open it.- If you see multiple, pick the one with the largest number i.e. if theres
flag_config.cfg.binandflag_config_0.01a.cfg.bin, pick the second option.
- If you see multiple, pick the one with the largest number i.e. if theres
- Click on
FLAG_INFO_1.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_1and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
Creating GlobalTBoxFlags
- Navigate over to
data/res/sys/ - There you will find a
flag_config.cfg.bin- open it.- If you see multiple, pick the one with the largest number i.e. if theres
flag_config.cfg.binandflag_config_0.01a.cfg.bin, pick the second option.
- If you see multiple, pick the one with the largest number i.e. if theres
- Click on
FLAG_INFO_2.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_2and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
Creating TempBitFlags
- Navigate over to
data/res/sys/ - There you will find a
flag_config.cfg.bin- open it.- If you see multiple, pick the one with the largest number i.e. if theres
flag_config.cfg.binandflag_config_0.01a.cfg.bin, pick the second option.
- If you see multiple, pick the one with the largest number i.e. if theres
- Click on
FLAG_INFO_3.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_3and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
Creating TempByteFlags
- Navigate over to
data/res/sys/ - There you will find a
flag_config.cfg.bin- open it.- If you see multiple, pick the one with the largest number i.e. if theres
flag_config.cfg.binandflag_config_0.01a.cfg.bin, pick the second option.
- If you see multiple, pick the one with the largest number i.e. if theres
- Click on
FLAG_INFO_4.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_4and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
Creating TempMapBitFlags
- Navigate over to
data/res/map/and open<mapName>.pck. - Open
<mapName>_flag.cfg.bin- If it is not there; the map has no TempMapBitFlags and you must copy the
cfg.binfrom another map.
- If it is not there; the map has no TempMapBitFlags and you must copy the
- Click on
FLAG_INFO_0.- Increase the
ChildCountby 1.
- Increase the
- Duplicate the last entry in
FLAG_INFO_0and select the newly created entry. - Increase the
FlagSlotby 1. - Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!
- Create a new ID for the
FlagIDfield, you can do this by typing anything into a website like this. - Save and Enjoy!