“根号三工作笔记”的版本间的差异

来自星际争霸重制版地图研究所
跳到导航 跳到搜索
第1行: 第1行:
<pre lang="Java" line="1">
<pre lang="Java"line="1">
var maxhp = dwread_epd(EPD(0x65FD00)+9808/4 + unittype) / 0x100;
var maxhp = dwread_epd(EPD(0x65FD00)+9808/4 + unittype) / 0x100;
foreach(ptr, epd : EUDLoopUnit() )  
foreach(ptr, epd : EUDLoopUnit() )  

2021年6月7日 (一) 20:15的版本

var maxhp = dwread_epd(EPD(0x65FD00)+9808/4 + unittype) / 0x100;
foreach(ptr, epd : EUDLoopUnit() ) 
{
	if(
		bread(ptr + 0x4C) == player &&
		wread(ptr + 0x64) == unittype &&
		dwread(ptr + 0x8) <= (maxhp - gainhp) * 0x100
		){
		dwwrite(ptr + 0x8, dwread(ptr + 0x8) + gainhp * 0x100);
		}
		else if(
				bread(ptr + 0x4C) == player &&
				wread(ptr + 0x64) == unittype &&
				dwread(ptr + 0x8) > (maxhp - gainhp) * 0x100
				)			
				{
				dwwrite(ptr + 0x8, maxhp * 0x100);
				}
}