Exp=f
@p1=
@c1=
@p2=
@c2=
@va=temp_a
@vb=b
@vc=c
@vd=d
ext=
mgs=
@end
public function long ysetvalue ( long a );
//YSetValue
//ĿģԱֵ
//aҪõֵ
//ؽҪõֵ
//LastError=0ȷLastErrorΪμֲ

	Boolean b_negative 
	b_negative = False //ֲڴǷ

byte InArray[16]
	byte DecArray []
    int n
	//칤ɵļܺļܱʽ
	//бܵıʽΪ@exp
	InArray[1]=@ak100;InArray[2]=@ak101;InArray[3]=@ak102; InArray[4]=@ak103;
	InArray[5]=@ak104;InArray[6]=@ak105;InArray[7]=@ak106; InArray[8]=@ak107;
	InArray[9]=@ak108;InArray[10]=@ak109;InArray[11]=@ak110;InArray[12]=@ak111;
	InArray[13]=@ak112;InArray[14]=@ak113;InArray[15]=@ak114;InArray[16]=@ak115;
	//ܺıʽ͵ннܲ¼ܣʹӦȨţעת
	//Ȼ󷵻ؼܺݣüܺüӦ
	//ֻбӦȨŽתݲܱӦļܲ
	for n=1 to 16
			DecArray[n]=0
	next 
	LastError=E_Dec_6(E_HKey, E_LKey, InArray, DecArray, KeyPath)
	if  LastError<> 0 then
	  return 0
	end if
///////////////////////////////////////////////////////////////////////////////////////  	
	
    If (a < 0) Then 
		a = -a
	 b_negative = True //ΪaΪȻø
	 end if
    //ֲ
    integer temp_a ,temp_b,temp_c,temp_d
    //a256ȡ
    //ΪCal_2ʽֻֽڱܳ256
    temp_a = a - (a / 256) * 256
    //aȥ
    //ΪʲôҪaȥأ
    //Ϊ׼ڼڲμ㣬aҪȥԼ
    a = a - temp_a
    integer result //ֲ,ؽ
    integer b 
    integer c 
    Integer d 
	b = rand(256)-1
	 c = rand(256)-1
	 d = rand(256)-1
    //ⲽa,bĸ͵ڲ,b,c,dԡ
    //@fļе@pλдмʽ
    result =  CalculateEx_2(DecArray,temp_a, b, c, d,KeyPath,16, 2000)

    @1
    If (result <> 0) Then
	 LastError = result //ô
	return 0
   end if
    //ڼĽصtemp_a
    //ٽǰȥaӾͿˡ
    If (b_negative) Then 
		return -(temp_a + a)//aΪֱtemp_aȻȡ
	end if
	 return temp_a + a //Ϊ,ֱtemp_a
end function

