Forum: HF Discussion
					
                  					
				 
	
					
                         by Apocalyman at 06-07-2020, 09:54 PM
						
1 comments
					
			  		Hello! first of all I would like to say thank you for doing what you did until now with the server+making the game into an exe and everything else related. I wanted to know if its possible to somehow continue updating this game? this game was my childhood and I even remember when chapters 6 and 7 came out and I was so excited to play them. its sad that this game is dead now. isnt it possible to do something? thank you! (sorry if this has been asked before I tried using the contact form but it says unauthorized or something like that)
			  		
			  		 
	
					
                         by MangaD at 05-07-2020, 12:24 PM
						
0 comments
					
			  		Introduction
It is possible to "convert" the SWF to an EXE using HF Workshop, which is actually just using Adobe Flash Player Projector to create a standalone of the SWF. There are many versions of the FP available for download, and you may download them here here.
Note: If you are curious about the algorithm HF Workshop is using, you may check it here.
However, HF Workshop does not customize the FP projector. So here are some instructions on how you can achieve this.
Note: The EXE must not be compressed with UPX for this to work.
Changing the icon
For changing the icon, you'll need Resource Editor. Open the Flash Player projector file (SA.exe), before adding HF swf to it, with resource editor. Expand the "Icon" folder, right click on the first icon, click on "Load resource..." and select the ICO file you want. If you don't have a ICO file but only an image, you can convert the image to ICO using any online tool, like https://icoconvert.com/. The official HF ICO is available here. You may do this for all the icons there, though one should be enough to change the displayed icon of the EXE file. You may then use this modified SA.exe to convert HF swf to exe.
Notes:
- The EXE must not be compressed with UPX for this to work.
- This must be done before combining HF swf with SA.exe.
Removing the menu bar
The menu bar is not very useful. Of all of its options, full screen is probably the only useful one, but this can be achieved with CTRL+F too. Removing this bar is actually easy. With Resource Editor again, open the EXE with it, expand the "Menu" folder and delete all the menu entries.
Changing the window's title
This one varies with the FP version. On old versions, I was told that using Resource Editor, changing the title can be done on the "String Table" folder. But on more recent versions (the oldest I tried was version 11), changing the title must be done with an hex editor. In version 11 and version 20 (the ones I tried), you have to search for
Note: Resource Hacker appears to break Trong's Flash Player. Resource Editor is a good alternative that works.
			  		
			  		It is possible to "convert" the SWF to an EXE using HF Workshop, which is actually just using Adobe Flash Player Projector to create a standalone of the SWF. There are many versions of the FP available for download, and you may download them here here.
Note: If you are curious about the algorithm HF Workshop is using, you may check it here.
However, HF Workshop does not customize the FP projector. So here are some instructions on how you can achieve this.
Note: The EXE must not be compressed with UPX for this to work.
Changing the icon
For changing the icon, you'll need Resource Editor. Open the Flash Player projector file (SA.exe), before adding HF swf to it, with resource editor. Expand the "Icon" folder, right click on the first icon, click on "Load resource..." and select the ICO file you want. If you don't have a ICO file but only an image, you can convert the image to ICO using any online tool, like https://icoconvert.com/. The official HF ICO is available here. You may do this for all the icons there, though one should be enough to change the displayed icon of the EXE file. You may then use this modified SA.exe to convert HF swf to exe.
Notes:
- The EXE must not be compressed with UPX for this to work.
- This must be done before combining HF swf with SA.exe.
Removing the menu bar
The menu bar is not very useful. Of all of its options, full screen is probably the only useful one, but this can be achieved with CTRL+F too. Removing this bar is actually easy. With Resource Editor again, open the EXE with it, expand the "Menu" folder and delete all the menu entries.
Changing the window's title
This one varies with the FP version. On old versions, I was told that using Resource Editor, changing the title can be done on the "String Table" folder. But on more recent versions (the oldest I tried was version 11), changing the title must be done with an hex editor. In version 11 and version 20 (the ones I tried), you have to search for
A\0d\0o\0b\0e\0 \0F\0l\0a\0s\0h\0 \0P\0l\0a\0y\0e\0r\0 \0X\0X, where the \0 represents the null byte (00 in hexadecimal) and appears between every character, and XX represents the version (11, 20...). After you've found this, you can write your own title on top of this (keeping the null bytes intact), and you must terminate the title with a null byte, and you also cannot have a title bigger than the already existing one, using this simple method. So, your title could look like: H\0e\0r\0o\0 \0F\0i\0g\0h\0t\0e\0r\0 \0v\00\0.\07\0+\0\0\0X\0XNote: Resource Hacker appears to break Trong's Flash Player. Resource Editor is a good alternative that works.
 
	
					
                         by asdfqwe at 03-07-2020, 08:53 PM
						
5 comments
					
			  		
			 
	
					
                         by MangaD at 21-06-2020, 03:43 PM
						
0 comments
					
			  		After talking with @不饿白帝BEBD, @Runningcake and @Lee Catalpa Tien (on QQ), I have grasped a few concepts of the SPT file. I'll leave a rough draft here, for future updates and development. Feel free to comment with your knowledge and improve it!
Overview of SPT file:
![[Image: spt.png]](https://i.postimg.cc/br7qqmMm/spt.png)
Making new moves requires modifying
In the attachment there is a much more complete tutorial file made by @Lee Catalpa Tien. Thanks to @nikhil for translating it to English!
			  		
Overview of SPT file:
![[Image: spt.png]](https://i.postimg.cc/br7qqmMm/spt.png)
- cadand- keyTgrarrays appear to be useless. Maybe leftovers from older versions.
 
- framesarray contains all the frames' data.- allowKeyTriggerattribute of a frame specifies whether or not we can perform an action (e.g. attack) from this frame.
 
- attackarray contains all the attacks that the character can perform while in this frame.- refNameis the name reference for an attack. The attacks are in the file- Data.Global_globalDat.
 
 
- actionarray contains all the possible actions of a character.- a_keyTgrspecifies the actions that can be TriGgeRed in the action state that it belongs to, as well as how to trigger them- rkt(restrict key trigger) if it is false,- allowKeyTriggerin frame is ignored. If it is true, it can be triggered only in frames of the action that have- allowKeyTriggerset to- true. Example: In STAND state,- rktshould be- falsefor a special move if we want to trigger it at any time. But during an attack or specific action,- rktshould be- trueso that only in certain frames (e.g. later frames) of the attack we can trigger another one.
 
- kkey combination to perform move to right.
 
- krkey combination to perform move to left (stands for key reverse).
 
- agiis the Action Group Index that this trigger corresponds to.
 
- ati- in an action group there is an- actionIndexarray,- atiis the index in this array.
 
- ai- each element of the- actionIndexarray is also an array, and- aiis the index of the element in this array that we want.
 
 
- frameIndexrefers to the frame where this action starts
 
 
- actionGroup- corresponds to a set of actions. Most common are- normal,- gua(guard),- cat(catch human),- hea(catch object),- rid(ride)- actionuseless array, probably leftover from older versions. It was moved to the outside- actionarray mentioned above. Now- actionGroupis linked to a set of actions through the attributes- ati,- agiand- aiinside- a_keyTgrinside of an action.
 
 
Making new moves requires modifying
actionGroup, action and frame arrays.- hire_id- array with type of soldiers for each possible unit (we have to use their id to get them, e.g.: "z_infantry01"). If you use a mount as id (e.g.- horse,- horse_monster,- horse_triceratops), they will be available to mount but won't attack on their own.
 
- hire_max- array with count of soldiers for each possible unit (for ex. lets say "z_infantry01" if we put its value to 1, then we get 4 soldiers, if 2 means then 8 soldiers)
 
- hire_price- array with costs to hire a unit, for each possible unit.
 
- hire_h- array with mounts for each possible unit. If "null" they are on foot. If "h" they are on horse. If "m" they are on monster. If "t" they are on triceratops. These mounts won't disappear when a soldier falls from them, they will be available to mount by the player or another soldier, except if the- hire_idis- z_cavalry01, then the mounts will disappear.
 
In the attachment there is a much more complete tutorial file made by @Lee Catalpa Tien. Thanks to @
                     Welcome, Guest
               | You have to register before you can post on our site. | 
			Search Forums
	
                     Forum Statistics
               | Members: 523 Latest member: Nicolas Forum threads: 353 Forum posts: 1,583 | 
                     Online Users
               | There are currently 199 online users. 0 Member(s) | 197 Guest(s) Applebot, Bing | 
			Upcoming Events
		
	| No upcoming events | 
                    Latest Threads
               | What song are you listeni...
Last by MangaD 46 Replies | 
| Hero Fighter X - Android ...
Last by MangaD 21 Replies | 
| HF Equilibrium Trevor v1....
Last by 不饿白帝BEBD 0 Replies | 
| 褚英招式用法
Last by Trickster 0 Replies | 
| Hero Fighter v0.7+
Last by MangaD 10 Replies | 
| Coal Gu's Artwork
Last by Coal_gu 1 Replies | 
| HFX Chaotic World
Last by MangaD 2 Replies | 
| HFX custom battle
Last by MangaD 3 Replies | 
| Remove the healing effect
Last by 不饿白帝BEBD 1 Replies | 
| Marti Wong's LF Remastere...
Last by Avodo 0 Replies | 

![[Image: Capture.png]](https://i.ibb.co/VtjJj3y/Capture.png)