if(jieduan=0)
        setpos(0,17,46,121,200)
	hero[2][1]
	hero[0][0]=119
	hero[1][0]=50
	addHero(hero)
	sethp(4,7000)
	setmp(4,7000)
	setJD(jieduan+1)
endif

if(jieduan=1)
	setspeed(4,126)
	hp=gethp(4)
	if(hp>5000)
		if(mod(count,9)=0)
			jieduan=4
		endif
		if(probability(70))
			act[2]
			act[0]=31
			act[1]=32
			randomContor(4,act)
		else
			setcontor(4,-1,0,0)
		endif
	else
		setspeed(4,999)
		sethp(4,10000)
		removeBuff(4,14)
		removeBuff(4,1)
		setcontor(4,2,1,34)
		talk[2]
		talk[0]="给我来场真正的挑战吧!"
		talk[1]="提示：战斗进入#第二阶段$"
		setTalk(4,talk)
		setJD(jieduan+1)
	endif
endif

if(jieduan=2)
	hp=gethp(4)
	setspeed(4,126)
	if(hp>5000)
		if(mod(count,5)=0)
			jieduan=4
		endif
		if(probability(70))
			act[3]
			act[0]=31
			act[1]=32
			act[2]=34
			randomContor(4,act)
		else
			setcontor(4,-1,0,0)
		endif
	else
		setspeed(4,999)
		sethp(4,3000)
		removeBuff(4,14)
		removeBuff(4,1)
		setcontor(4,-1,1,33)
		talk[2]
		talk[0]="光明之刃!"
		talk[1]="提示：战斗进入#第三阶段$"
		setTalk(4,talk)
		setJD(jieduan+1)
	endif
endif

if(jieduan=3)
	removeBuff(4,34)
	setspeed(4,126)
	if(mod(count,3)=0)
		jieduan=4
	endif
	if(mod(count,6)>3)
		act[1]
		act[0]=33
		randomContor(4,act)
	else
		setcontor(4,-1,0,0)
	endif
endif

if(jieduan=4)
	setspeed(4,999)
	addBuff(4,8,1,0)
	if(mod(count,2)=1)
		talk[2]
		talk[0]="哈，你们就这点本事？"
		talk[1]="战斗提示：修真者#无敌一回合$，角色#攻击随回合数削弱$"
		setTalk(4,talk)
		removeBuff(1,24)
		removeBuff(2,24)
		removeBuff(3,24)
		addBuff(1,24,-1,count*30)
		addBuff(2,24,-1,count*30)
		addBuff(3,24,-1,count*30)
		setcontor(4,-1,1,43)
	else
		talk[2]
		talk[0]="圣光,赐予我力量吧！"
		talk[1]="战斗提示：修真者#无敌一回合$，#攻击随回合数暂时增强$"
		setTalk(4,talk)
		removeBuff(4,9)
		addBuff(4,9,2,count*30)
		setcontor(4,-1,1,43)
	endif
endif

ret
