*Set Var oflagElmIDMerge=1
*If(GenData(Show_Surface_Loads_In_Post-Processor,Int)==0)
*Set Var oflagElmIDMerge=0
*EndIf

*Set Var eLoadFire=0
*Set Cond Moisture_Temperature_Boundary_for_Line *elems *CanRepeat 
*If(ndime==3)
*Set Cond Moisture_Temperature_Boundary_for_Surface *elems *CanRepeat 
*EndIf
*If(CondNumEntities(Int)>0)
// selection has *CondNumEntities entities
*Set Var nshells=0
*Set Var nbeam=0
*loop elems *OnlyInCond
*#
*include ..\include.src.bas\CurrentElementGroupID.bas

*Set Var oflagElmIDMerge=1
Load MOIST_TEMP_BOUNDARY GROUP *groupID *tcl(TK_ElementNum *oflagElmIDMerge *ElemsNum) *\
*#
*# nastavim si abych do stepu pridal load case
*Set Var IsIntervalWithFire=1
*#
*#
                   AMBIENT_TEMPERATURE *Cond(Ambient_Temperature,Real) 
*If(strcmp(Cond(AmbiTemper_FUNCTION_TYPE),"FUNCTION_FROM_MATERIAL")==0)
*Set Var oMujMat=tcl(TK_FindMaterialNumber *Cond(AmbiTemper_FUNCTION_MAT) "Moisture_Temperature_Boundary_for")
                   TEMP_FUNCTION *Operation(25250000+oMujMat)
*EndIf                    
                   HUMIDITY *Cond(Humidity,Real)
*If(strcmp(Cond(Humidity_FUNCTION_TYPE),"FUNCTION_FROM_MATERIAL")==0)
*Set Var oMujMat=tcl(TK_FindMaterialNumber *Cond(Humidity_FUNCTION_MAT) "Moisture_Temperature_Boundary_for")
                   MOIST_FUNCTION *Operation(25250000+oMujMat)
*EndIf                    
*#
                   *Cond(TEMPERATURE) GRADIENT OF TEMPERATURE
*If(strcmp(Cond(HEAT_CONVECTION_AND_RADIATION),"1")==0)
                   CONVECTION_T *Cond(Convection_T,Real) 
                   EMISSIVITY_T *Cond(Emissivity_T,Real)
*EndIf                   
*#
                   *Cond(EVAPORATED_MOISTURE) GRADIENT OF EVAPORATED_MOISTURE 
*If(strcmp(Cond(HEAT_EVAPORATION),"1")==0)
                   EVAPORATION_HEAT *Cond(EVAPORATION_HEAT,Real)
*EndIf  
*#
                   *Cond(HUMIDITY_CEMSTONE_CALC) GRADIENT OF HUMIDITY_CEMSTONE_CALC 
*#
                   *Cond(RELATIVE_HUMIDITY) GRADIENT OF RELATIVE_HUMIDITY  
*If(strcmp(Cond(MOISTURE_CONVECTION),"1")==0)
                   CONVECTION_W *Cond(Convection_W,Real)  
*EndIf  
*#
                   *Cond(HUMIDITY_RATIO) GRADIENT OF HUMIDITY_RATIO  
*If(strcmp(Cond(MOISTURE_EVAPORATION),"1")==0)
                   EVAPORATION_MOISTURE *Cond(EVAPORATION_MOISTURE,Real)
                   AIR_PRESSURE *Cond(AIR_PRESSURE,Real) 
                   AIR_VELOCITY *Cond(AIR_VELOCITY,Real)
*If(strcmp(Cond(AirVelocity_FUNCTION_TYPE),"FUNCTION_FROM_MATERIAL")==0)
*Set Var oMujMat=tcl(TK_FindMaterialNumber *Cond(AirVelocity_FUNCTION_MAT) "Moisture_Temperature_Boundary_for")
                   AIR_FUNCTION *Operation(25250000+oMujMat)
*EndIf                        
*EndIf  
*#    
                   NODES *\
*Format "%i%i%i%s%i%i"
			"$N$I*IntervalIndex *ElemsType *ElemsNnode *Cond(Boundary)Num*Cond(Entity_number,Int) ElemNum*ElemsNum" *Cond(Boundary) *tcl(TK_BoundaryMerge *oflagElmIDMerge) 
*Set Var eLoadFire=Operation(eLoadFire+1)
*End elems
*EndIf
