# Macro Name    : stope_dtm.cmd
#
# Version       : surpac2000 V3.2-M 
#
# Creation Date : Tue Dec 18 09:39:43 2001
#
# Description   : This macro create a solid of stoped out areas.  An expanded DTM of floors must be create beforehand called f[level.DTM
#
# ----------------------------------------------------------------------
#
@SET fromlevel=@(1:prompt=LEVEL TO BE PROCESSED)
@SET tolevel=@(1:prompt=NEXT LEVEL UP)
#
@assign OBJ=fromlevel + 1
@assign shift=(tolevel-fromlevel)*0.268
#
@FUNCTION GRAPHICS,error=abort,mismatch=display
#
# GRAPHICS MENU
#
@menu("00025")
@FUNCTION RECALL FILE,error=abort,mismatch=display
#
# RECALL A FILE FORM
#
@FORM frm00236,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=mas:grl\
  |rid=@(fromlevel)\
  |string_rng=76\
  |ftype=S\
  |swa_desc=Y\
  |append=R\
  |styles_file=SSI_STYLES:styles.ssi\
  |rescale=Y\
  |swa_name=main graphics layer
#
# EDIT MENU
#
@menu("00019")
@FUNCTION STRING RENUMBER RANGE,error=abort,mismatch=display
#
# STRING RENUMBER RANGE FORM
#
@FORM frm00068,action=apply,pause=0.000000,error=abort,mismatch=display\
  |old_str_range=76\
  |new_str_range=1
@FUNCTION SAVE FILE,error=abort,mismatch=display
#
# UNLOAD STRINGS TO A FILE FORM
#
@FORM frm00287,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=ls\
  |rid=@(fromlevel)\
  |ftype=S\
  |purpose=\
  |range=\
  |format=text
@FUNCTION STRING RENUMBER,error=abort,mismatch=display
@FORM select_point,action=cancel,pause=0.000000,error=abort,mismatch=display
@FUNCTION STRING RENUMBER RANGE,error=abort,mismatch=display
#
# STRING RENUMBER RANGE FORM
#
@FORM frm00068,action=apply,pause=0.000000,error=abort,mismatch=display\
  |old_str_range=1\
  |new_str_range=6
@FUNCTION SAVE FILE,error=abort,mismatch=display
#
# UNLOAD STRINGS TO A FILE FORM
#
@FORM frm00287,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=us\
  |rid=@(fromlevel)\
  |ftype=S\
  |purpose=\
  |range=\
  |format=text
@menu("previous")
@FUNCTION EXIT GRAPHICS,error=abort,mismatch=display
#
# EXIT GRAPHICS FORM
#
@FORM frm00107,action=apply,pause=0.000000,error=abort,mismatch=display
#
# STRING TOOLS MENU
#
#@menu("00039")
#@FUNCTION STR MATHS,error=abort,mismatch=display
#@FORM frm00700,action=cancel,pause=0.000000,error=abort,mismatch=display
#@FUNCTION STR MATHS,error=abort,mismatch=display
#@FORM frm00700,action=cancel,pause=0.000000,error=abort,mismatch=display
@FUNCTION STRING MATHS,error=abort,mismatch=display
#
# STRING MATHS UTILITY FORM
#
@FORM frm00269,action=apply,pause=0.000000,error=abort,mismatch=display\
  |inloc=us\
  |idrange=@(fromlevel)\
  |ftype=S\
  |swa_desc=Y\
  |outloc=us\
  |num_ranges=1
#
# STRING MATHS  - DEFINE REQUIRED OPERATIONS FORM
#
@FORM frm00270,action=apply,pause=0.000000,error=abort,mismatch=display\
  |strange=6\
  |opfld1=Y\
  |op1=-\
  |value1=@(shift)\
  |opfld2=\
  |op2==\
  |value2=\
  |opfld3=\
  |op3==\
  |value3=\
  |opfld4=\
  |op4==\
  |value4=\
  |opfld5=\
  |op5==\
  |value5=\
  |opfld6=\
  |op6==\
  |value6=\
  |opfld7=\
  |op7==\
  |value7=\
  |opfld8=\
  |op8==\
  |value8=\
  |opfld9=\
  |op9==\
  |value9=\
  |opfld10=\
  |op10==\
  |value10=
@menu("previous")
#
# DTM TOOLS MENU
#
@menu("00017")
@FUNCTION STRINGS OVER DTM,error=abort,mismatch=display
#
# OVERLAY STRINGS ON A DTM FORM
#
@FORM frm00209,action=apply,pause=0.000000,error=abort,mismatch=display\
  |dtmloc=f\
  |dtmid=@(fromlevel)\
  |swadesc=Y\
  |bdyopt=N\
  |interp=N\
  |inploc=ls\
  |rinpid=@(fromlevel)\
  |strange=\
  |outloc=ls\
  |outid=@(fromlevel)
#
# VERIFY CREATION OF A FILE FORM
#
@FORM frm00121,action=apply,pause=0.000000,error=abort,mismatch=ignore
#
# DEFINE REQUIRED OPERATIONS FORM
#
@FORM frm00608,action=apply,pause=0.000000,error=abort,mismatch=display\
  |strfld1=Z\
  |op1==\
  |dtmfld1=Z\
  |strfld2=\
  |op2==\
  |dtmfld2=\
  |strfld3=\
  |op3==\
  |dtmfld3=\
  |strfld4=\
  |op4==\
  |dtmfld4=\
  |strfld5=\
  |op5==\
  |dtmfld5=\
  |strfld6=\
  |op6==\
  |dtmfld6=\
  |strfld7=\
  |op7==\
  |dtmfld7=\
  |strfld8=\
  |op8==\
  |dtmfld8=\
  |strfld9=\
  |op9==\
  |dtmfld9=\
  |strfld10=\
  |op10==\
  |dtmfld10=
@FUNCTION STRINGS OVER DTM,error=abort,mismatch=display
#
# OVERLAY STRINGS ON A DTM FORM
#
@FORM frm00209,action=apply,pause=0.000000,error=abort,mismatch=display\
  |dtmloc=f\
  |dtmid=@(tolevel)\
  |swadesc=Y\
  |bdyopt=N\
  |interp=N\
  |inploc=us\
  |rinpid=@(fromlevel)\
  |strange=\
  |outloc=us\
  |outid=@(fromlevel)
#
# VERIFY CREATION OF A FILE FORM
#
@FORM frm00121,action=apply,pause=0.000000,error=abort,mismatch=ignore
#
# DEFINE REQUIRED OPERATIONS FORM
#
@FORM frm00608,action=apply,pause=0.000000,error=abort,mismatch=display\
  |strfld1=Z\
  |op1==\
  |dtmfld1=Z\
  |strfld2=\
  |op2==\
  |dtmfld2=\
  |strfld3=\
  |op3==\
  |dtmfld3=\
  |strfld4=\
  |op4==\
  |dtmfld4=\
  |strfld5=\
  |op5==\
  |dtmfld5=\
  |strfld6=\
  |op6==\
  |dtmfld6=\
  |strfld7=\
  |op7==\
  |dtmfld7=\
  |strfld8=\
  |op8==\
  |dtmfld8=\
  |strfld9=\
  |op9==\
  |dtmfld9=\
  |strfld10=\
  |op10==\
  |dtmfld10=
@FUNCTION GRAPHICS,error=abort,mismatch=display
#
# GRAPHICS MENU
#
@menu("00025")
@FUNCTION RECALL FILE,error=abort,mismatch=display
#
# RECALL A FILE FORM
#
@FORM frm00236,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=ls\
  |rid=@(fromlevel)\
  |string_rng=\
  |ftype=S\
  |swa_desc=Y\
  |append=R\
  |styles_file=SSI_STYLES:styles.ssi\
  |rescale=Y\
  |swa_name=main graphics layer
@FUNCTION RECALL FILE,error=abort,mismatch=display
#
# RECALL A FILE FORM
#
@FORM frm00236,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=us\
  |rid=@(fromlevel)\
  |string_rng=\
  |ftype=S\
  |swa_desc=Y\
  |append=A\
  |rescale=Y\
  |swa_name=main graphics layer
@FUNCTION VIEW BY BEARING,error=abort,mismatch=display
#
# SPECIFY VIEW BY BEARING AND DIP FORM
#
@FORM frm00289,action=apply,pause=0.000000,error=abort,mismatch=display\
  |bearing=135\
  |dip=-15
#
# Solids & DTM MENU
#
#@menu("00060")
#
# CREATE 3DM MENU
#
#@menu("00062")
@range(seg="1,200,1")
@FUNCTION TRIANGULATE MANY SEGMENTS,error=continue,mismatch=display
#
# DEFINE THE TRISOLATION TO BE CREATED FORM
#
@FORM frm00459,action=apply,pause=0.000000,error=abort,mismatch=display\
  |iobj=@(OBJ)\
  |itrisol=1
#
# TRIANGULATE MANY SEGMENTS OPTIONS FORM
#
@FORM frm00651,action=apply,pause=0.000000,error=abort,mismatch=display\
  |theopt1=Y\
  |theopt2=R\
  |theopt3=V
#
# RANGE DEFINITION FORM
#
@FORM frm00655,action=apply,pause=0.000000,error=abort,mismatch=display\
  |str_seg=STR\
  |seg_no=@(seg)\
  |str_rg=1;6
@endrange
#
@FUNCTION SAVE FILE,error=abort,mismatch=display
#
# UNLOAD STRINGS TO A FILE FORM
#
@FORM frm00287,action=apply,pause=0.000000,error=abort,mismatch=display\
  |location=stope\
  |rid=@(fromlevel)\
  |ftype=D\
  |purpose=us@(fromlevel).STR overlaid on b@(tolevel).DT\
  |range=\
  |format=text

