Index: class.doc ================================================================== --- class.doc +++ class.doc @@ -977,17 +977,25 @@ BroadcastSumEx ( class message arg1 arg2 arg3 -- total ) As BroadcastSum but with three message arguments. bxor ( in1 in2 -- out ) Bitwise XOR. + +c? ( any -- bool ) + True if the value is a class, or false if it is any other type. Error if + it is a sound. Create ( class x y image dir -- obj ) ** Creates a new object at the specified location, and returns it. The result is zero if the class is zero, the coordinates are out of range, the object cannot be created due to the CollisionLayers, or if the new object is destroyed before its CREATE message returns. +cz? ( any -- bool ) + True if the value is a class or zero, or false if it is neither a class + nor zero. Error if it is a sound. + DelInventory ( class image -- ) ** Delete an item from the inventory; see SetInventory for more details. Delta ( in1 in2 -- out ) Subtracts the smaller input from the larger (unsigned). @@ -1127,10 +1135,14 @@ ,lt ( in1 in2 -- bool ) Test if first input is less than second input (signed). lxor ( in1 in2 -- out ) Logical XOR. + +m? ( any -- bool ) + True if the value is a message, or false if it is any other type. Error + if it is a sound. MaxInventory ( number -- ) Results in an error and loss of game if the number of different inventory items exceeds the given number, otherwise no effect. @@ -1170,10 +1182,14 @@ ,MoveTo ( obj x y -- bool ) ** As MoveTo but for a specified object, not necessarily this one. Msg ( -- message ) The current message being processed. + +n? ( any -- bool ) + True if the value is a number, or false if it is any other type. Error + if it is a sound. ne ( in1 in2 -- bool ) As eq but the result is inverted (like "eq lnot"). neg ( in -- out ) @@ -1188,10 +1204,14 @@ NewY ( oldx dir -- newy ) Advance the number in the direction as though it is a Y coordinate. nip ( x y -- y ) +o? ( any -- bool ) + True if the value is an object (whether or not it has been garbage + collected), or false for any other type. Error if it is a sound. + ObjAbove ( -- obj ) The object above this one (0 if this one is at the top). "Above" means it overlaps this object, not upward on the screen (north). ,ObjAbove ( obj -- obj ) @@ -1230,10 +1250,15 @@ ObjTopAt ( x y -- obj ) Find the object on the top at the specified location. The result will be zero if that location is vacant or out of range. +oz? ( any -- bool ) + True if the value is an object or zero, or false if it is neither an + object nor zero. (Even if the object has been garbage collected, it is + still true.) Error if it is a sound. + PopUp ( value -- ) Displays a popup message. Normally, the value is a string, but it can be another type, and it will try to display it. If the text contains any \q commands, then dismissing the popup message will send a KEY message to the object which created the popup message. If there is already another @@ -1273,10 +1298,15 @@ ,rsh ( in shift -- out ) Arithmetic right shift. If the shift amount is out of the range 0-31, then all bits are shifted out; the result will be -1 if the input is negative, or 0 otherwise. + +s? ( any -- bool ) + True if the value is a string (which may be either a string in the class + codes or a string in the level), or false if it is any other type. Error + if it is a sound. Self ( -- obj ) The reference to the current object. Send ( message arg1 arg2 -- value ) Index: exec.c ================================================================== --- exec.c +++ exec.c @@ -1249,11 +1249,12 @@ #define GetVariableOrAttributeOf(a,b) (t2=Pop(),t2.t==TY_CLASS?NVALUE(classes[t2.u]->a):(i=v_object(t2),i==VOIDLINK?NVALUE(0):b(objects[i]->a))) #define Numeric(a) do{ if((a).t!=TY_NUMBER) Throw("Type mismatch"); }while(0) #define DivideBy(a) do{ Numeric(a); if(!(a).u) Throw("Division by zero"); }while(0) #define GetFlagOf(a) t2=Pop(),Push(t2.t==TY_CLASS?NVALUE(classes[t2.u]->oflags&a?1:0):(i=v_object(t2),i==VOIDLINK?NVALUE(0):NVALUE(objects[i]->oflags&a?1:0))) #define GetClassFlagOf(a) t2=Pop(),Push(t2.t==TY_CLASS?NVALUE(classes[t2.u]->cflags&a?1:0):(i=v_object(t2),i==VOIDLINK?NVALUE(0):NVALUE(classes[objects[i]->class]->cflags&a?1:0))) -#define SetFlagOf(a) do { t2=Pop(); i=v_object(Pop()); if(i!=VOIDLINK) { if(v_bool(t2)) objects[i]->oflags|=a; else objects[i]->oflags&=~a; } }while(0) +#define SetFlagOf(a) do{ t2=Pop(); i=v_object(Pop()); if(i!=VOIDLINK) { if(v_bool(t2)) objects[i]->oflags|=a; else objects[i]->oflags&=~a; } }while(0) +#define NotSound(a) do{ if((a).t==TY_SOUND || (a).t==TY_USOUND) Throw("Cannot convert sound to type"); }while(0) static void execute_program(Uint16*code,int ptr,Uint32 obj) { Uint32 i,j; Object*o=objects[obj]; Value t1,t2; static Value t3,t4,t5; @@ -1495,10 +1496,17 @@ case OP_OBJTOPAT: StackReq(2,1); t2=Pop(); Numeric(t2); t1=Pop(); Numeric(t1); i=obj_top_at(t1.u,t2.u); Push(OVALUE(i)); break; case OP_PLAYER: StackReq(0,1); if(classes[o->class]->cflags&CF_PLAYER) Push(NVALUE(1)); else Push(NVALUE(0)); break; case OP_PLAYER_C: StackReq(1,1); GetClassFlagOf(CF_PLAYER); break; case OP_POPUP: StackReq(1,0); v_set_popup(obj,0); break; case OP_POPUPARGS: i=code[ptr++]; StackReq(i+1,0); v_set_popup(obj,i); break; + case OP_QC: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t==TY_CLASS) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QCZ: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t==TY_CLASS || (t1.t==TY_NUMBER && !t1.u)) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QM: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t==TY_MESSAGE) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QN: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t==TY_NUMBER) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QO: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t>TY_MAXTYPE) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QOZ: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t>TY_MAXTYPE || (t1.t==TY_NUMBER && !t1.u)) Push(NVALUE(1)); else Push(NVALUE(0)); break; + case OP_QS: StackReq(1,1); t1=Pop(); NotSound(t1); if(t1.t==TY_STRING || t1.t==TY_LEVELSTRING) Push(NVALUE(1)); else Push(NVALUE(0)); break; case OP_RET: return; case OP_ROT: StackReq(3,3); t3=Pop(); t2=Pop(); t1=Pop(); Push(t2); Push(t3); Push(t1); break; case OP_ROTBACK: StackReq(3,3); t3=Pop(); t2=Pop(); t1=Pop(); Push(t3); Push(t1); Push(t2); break; case OP_RSH: StackReq(2,1); t2=Pop(); Numeric(t2); t1=Pop(); Numeric(t1); Push(NVALUE(t2.u&~31?0:t1.u>>t2.u)); break; case OP_RSH_C: StackReq(2,1); t2=Pop(); Numeric(t2); t1=Pop(); Numeric(t1); Push(NVALUE(t2.u&~31?(t1.s<0?-1:0):t1.s>>t2.u)); break; Index: instruc ================================================================== --- instruc +++ instruc @@ -120,10 +120,19 @@ ,gt ,lt ,ge ,le is + +; Type checks +qn "n?" +qc "c?" +qcz "cz?" +qm "m?" +qs "s?" +qo "o?" +qoz "oz?" ; Standard variables ,Class ,=!Temperature ,=Shape Index: instruc.h ================================================================== --- instruc.h +++ instruc.h @@ -58,308 +58,315 @@ #define OP_GE 32810 #define OP_GE_C 34858 #define OP_LE 32811 #define OP_LE_C 34859 #define OP_IS 32812 -#define OP_CLASS 32813 -#define OP_CLASS_C 34861 -#define OP_TEMPERATURE 32814 -#define OP_TEMPERATURE_C 34862 -#define OP_TEMPERATURE_E 36910 -#define OP_TEMPERATURE_EC 38958 -#define OP_TEMPERATURE_EC16 38959 -#define OP_TEMPERATURE_E16 36911 -#define OP_SHAPE 32816 -#define OP_SHAPE_C 34864 -#define OP_SHAPE_E 36912 -#define OP_SHAPE_EC 38960 -#define OP_XLOC 32817 -#define OP_XLOC_C 34865 -#define OP_YLOC 32818 -#define OP_YLOC_C 34866 -#define OP_DIR 32819 -#define OP_DIR_C 34867 -#define OP_DIR_E 36915 -#define OP_DIR_EC 38963 -#define OP_IMAGE 32820 -#define OP_IMAGE_C 34868 -#define OP_IMAGE_E 36916 -#define OP_IMAGE_EC 38964 -#define OP_INERTIA 32821 -#define OP_INERTIA_C 34869 -#define OP_INERTIA_E 36917 -#define OP_INERTIA_EC 38965 -#define OP_INERTIA_EC16 38966 -#define OP_INERTIA_E16 36918 -#define OP_DISTANCE 32823 -#define OP_DISTANCE_C 34871 -#define OP_DISTANCE_E 36919 -#define OP_DISTANCE_EC 38967 -#define OP_DISTANCE_EC16 38968 -#define OP_DISTANCE_E16 36920 -#define OP_DENSITY 32825 -#define OP_DENSITY_C 34873 -#define OP_DENSITY_E 36921 -#define OP_DENSITY_EC 38969 -#define OP_DENSITY_EC16 38970 -#define OP_DENSITY_E16 36922 -#define OP_VOLUME 32827 -#define OP_VOLUME_C 34875 -#define OP_VOLUME_E 36923 -#define OP_VOLUME_EC 38971 -#define OP_VOLUME_EC16 38972 -#define OP_VOLUME_E16 36924 -#define OP_WEIGHT 32829 -#define OP_WEIGHT_C 34877 -#define OP_WEIGHT_E 36925 -#define OP_WEIGHT_EC 38973 -#define OP_WEIGHT_EC16 38974 -#define OP_WEIGHT_E16 36926 -#define OP_HEIGHT 32831 -#define OP_HEIGHT_C 34879 -#define OP_HEIGHT_E 36927 -#define OP_HEIGHT_EC 38975 -#define OP_HEIGHT_EC16 38976 -#define OP_HEIGHT_E16 36928 -#define OP_CLIMB 32833 -#define OP_CLIMB_C 34881 -#define OP_CLIMB_E 36929 -#define OP_CLIMB_EC 38977 -#define OP_CLIMB_EC16 38978 -#define OP_CLIMB_E16 36930 -#define OP_STRENGTH 32835 -#define OP_STRENGTH_C 34883 -#define OP_STRENGTH_E 36931 -#define OP_STRENGTH_EC 38979 -#define OP_STRENGTH_EC16 38980 -#define OP_STRENGTH_E16 36932 -#define OP_HARD 32837 -#define OP_HARD_C 34885 -#define OP_HARD_E 36933 -#define OP_HARD_EC 38981 -#define OP_SHARP 32838 -#define OP_SHARP_C 34886 -#define OP_SHARP_E 36934 -#define OP_SHARP_EC 38982 -#define OP_SHAPEDIR 32839 -#define OP_SHAPEDIR_C 34887 -#define OP_SHAPEDIR_E 36935 -#define OP_SHAPEDIR_EC 38983 -#define OP_SHOVABLE 32840 -#define OP_SHOVABLE_C 34888 -#define OP_SHOVABLE_E 36936 -#define OP_SHOVABLE_EC 38984 -#define OP_MISC1 32841 -#define OP_MISC1_C 34889 -#define OP_MISC1_E 36937 -#define OP_MISC1_EC 38985 -#define OP_MISC1_EC16 38986 -#define OP_MISC1_E16 36938 -#define OP_MISC2 32843 -#define OP_MISC2_C 34891 -#define OP_MISC2_E 36939 -#define OP_MISC2_EC 38987 -#define OP_MISC2_EC16 38988 -#define OP_MISC2_E16 36940 -#define OP_MISC3 32845 -#define OP_MISC3_C 34893 -#define OP_MISC3_E 36941 -#define OP_MISC3_EC 38989 -#define OP_MISC3_EC16 38990 -#define OP_MISC3_E16 36942 -#define OP_MISC4 32847 -#define OP_MISC4_C 34895 -#define OP_MISC4_E 36943 -#define OP_MISC4_EC 38991 -#define OP_MISC4_EC16 38992 -#define OP_MISC4_E16 36944 -#define OP_MISC5 32849 -#define OP_MISC5_C 34897 -#define OP_MISC5_E 36945 -#define OP_MISC5_EC 38993 -#define OP_MISC5_EC16 38994 -#define OP_MISC5_E16 36946 -#define OP_MISC6 32851 -#define OP_MISC6_C 34899 -#define OP_MISC6_E 36947 -#define OP_MISC6_EC 38995 -#define OP_MISC6_EC16 38996 -#define OP_MISC6_E16 36948 -#define OP_MISC7 32853 -#define OP_MISC7_C 34901 -#define OP_MISC7_E 36949 -#define OP_MISC7_EC 38997 -#define OP_MISC7_EC16 38998 -#define OP_MISC7_E16 36950 -#define OP_ARRIVED 32855 -#define OP_ARRIVED_C 34903 -#define OP_ARRIVED_E 36951 -#define OP_ARRIVED_EC 38999 -#define OP_DEPARTED 32856 -#define OP_DEPARTED_C 34904 -#define OP_DEPARTED_E 36952 -#define OP_DEPARTED_EC 39000 -#define OP_ARRIVALS 32857 -#define OP_ARRIVALS_C 34905 -#define OP_ARRIVALS_E 36953 -#define OP_ARRIVALS_EC 39001 -#define OP_DEPARTURES 32858 -#define OP_DEPARTURES_C 34906 -#define OP_DEPARTURES_E 36954 -#define OP_DEPARTURES_EC 39002 -#define OP_BUSY 32859 -#define OP_BUSY_C 34907 -#define OP_BUSY_E 36955 -#define OP_BUSY_EC 39003 -#define OP_INVISIBLE 32860 -#define OP_INVISIBLE_C 34908 -#define OP_INVISIBLE_E 36956 -#define OP_INVISIBLE_EC 39004 -#define OP_KEYCLEARED 32861 -#define OP_KEYCLEARED_C 34909 -#define OP_KEYCLEARED_E 36957 -#define OP_KEYCLEARED_EC 39005 -#define OP_USERSIGNAL 32862 -#define OP_USERSIGNAL_C 34910 -#define OP_USERSIGNAL_E 36958 -#define OP_USERSIGNAL_EC 39006 -#define OP_USERSTATE 32863 -#define OP_USERSTATE_C 34911 -#define OP_USERSTATE_E 36959 -#define OP_USERSTATE_EC 39007 -#define OP_VISUALONLY 32864 -#define OP_VISUALONLY_C 34912 -#define OP_VISUALONLY_E 36960 -#define OP_VISUALONLY_EC 39008 -#define OP_STEALTHY 32865 -#define OP_STEALTHY_C 34913 -#define OP_STEALTHY_E 36961 -#define OP_STEALTHY_EC 39009 -#define OP_MOVED 32866 -#define OP_MOVED_C 34914 -#define OP_MOVED_E 36962 -#define OP_MOVED_EC 39010 -#define OP_DONE 32867 -#define OP_DONE_C 34915 -#define OP_DONE_E 36963 -#define OP_DONE_EC 39011 -#define OP_DESTROYED 32868 -#define OP_DESTROYED_C 34916 -#define OP_PLAYER 32869 -#define OP_PLAYER_C 34917 -#define OP_COMPATIBLE 32870 -#define OP_COMPATIBLE_C 34918 -#define OP_COLLISIONLAYERS 32871 -#define OP_COLLISIONLAYERS_C 34919 -#define OP_SELF 32872 -#define OP_MSG 32873 -#define OP_FROM 32874 -#define OP_ARG1 32875 -#define OP_ARG1_E 36971 -#define OP_ARG2 32876 -#define OP_ARG2_E 36972 -#define OP_ARG3 32877 -#define OP_ARG3_E 36973 -#define OP_MOVENUMBER 32878 -#define OP_LEVEL 32879 -#define OP_KEY 32880 -#define OP_BACKGROUND 32881 -#define OP_INPUT 32882 -#define OP_QUIZ 32883 -#define OP_INPLACE 32884 -#define OP_DEFAULTIMAGE 32885 -#define OP_HELP 32886 -#define OP_EDITORHELP 32887 -#define OP_SUBS 32888 -#define OP_ANIMATE 32889 -#define OP_ASSASSINATE 32890 -#define OP_ASSASSINATE_C 34938 -#define OP_BROADCAST 32891 -#define OP_BROADCAST_D 41083 -#define OP_BROADCASTCLASS 32892 -#define OP_BROADCASTEX 32893 -#define OP_BROADCASTEX_D 41085 -#define OP_BROADCASTSUM 32894 -#define OP_BROADCASTSUMEX 32895 -#define OP_CREATE 32896 -#define OP_CREATE_D 41088 -#define OP_DELINVENTORY 32897 -#define OP_DELTA 32898 -#define OP_DESTROY 32899 -#define OP_DESTROY_C 34947 -#define OP_DESTROY_D 41091 -#define OP_DESTROY_CD 43139 -#define OP_FLUSHCLASS 32900 -#define OP_FLUSHOBJ 32901 -#define OP_FLUSHOBJ_C 34949 -#define OP_GETINVENTORY 32902 -#define OP_HEIGHTAT 32903 -#define OP_IGNOREKEY 32904 -#define OP_INTMOVE 32905 -#define OP_INTMOVE_C 34953 -#define OP_INTMOVE_D 41097 -#define OP_INTMOVE_CD 43145 -#define OP_JUMPTO 32906 -#define OP_JUMPTO_C 34954 -#define OP_JUMPTO_D 41098 -#define OP_JUMPTO_CD 43146 -#define OP_LOC 32907 -#define OP_LOC_C 34955 -#define OP_LOCATEME 32908 -#define OP_LOSELEVEL 32909 -#define OP_MAXINVENTORY 32910 -#define OP_MOVE 32911 -#define OP_MOVE_C 34959 -#define OP_MOVE_D 41103 -#define OP_MOVE_CD 43151 -#define OP_MOVEPLUS 32912 -#define OP_MOVEPLUS_C 34960 -#define OP_MOVEPLUS_D 41104 -#define OP_MOVEPLUS_CD 43152 -#define OP_MOVETO 32913 -#define OP_MOVETO_C 34961 -#define OP_MOVETO_D 41105 -#define OP_MOVETO_CD 43153 -#define OP_NEWX 32914 -#define OP_NEWY 32915 -#define OP_OBJABOVE 32916 -#define OP_OBJABOVE_C 34964 -#define OP_OBJBELOW 32917 -#define OP_OBJBELOW_C 34965 -#define OP_OBJBOTTOMAT 32918 -#define OP_OBJCLASSAT 32919 -#define OP_OBJDIR 32920 -#define OP_OBJDIR_C 34968 -#define OP_OBJLAYERAT 32921 -#define OP_OBJTOPAT 32922 -#define OP_POPUP 32923 -#define OP_POPUPARGS 32924 -#define OP_QUEUETURN 32925 -#define OP_SEND 32926 -#define OP_SEND_C 34974 -#define OP_SEND_D 41118 -#define OP_SEND_CD 43166 -#define OP_SENDEX 32927 -#define OP_SENDEX_C 34975 -#define OP_SENDEX_D 41119 -#define OP_SENDEX_CD 43167 -#define OP_SETINVENTORY 32928 -#define OP_SOUND 32929 -#define OP_SYNCHRONIZE 32930 -#define OP_TRACE 32931 -#define OP_VOLUMEAT 32932 -#define OP_WINLEVEL 32933 -#define OP_XDIR 32934 -#define OP_XDIR_C 34982 -#define OP_YDIR 32935 -#define OP_YDIR_C 34983 -#define OP_FUNCTION 32936 -#define OP_LOCAL 32937 -#define OP_LABEL 32938 -#define OP_STRING 32939 -#define OP_INT16 32940 -#define OP_INT32 32941 +#define OP_QN 32813 +#define OP_QC 32814 +#define OP_QCZ 32815 +#define OP_QM 32816 +#define OP_QS 32817 +#define OP_QO 32818 +#define OP_QOZ 32819 +#define OP_CLASS 32820 +#define OP_CLASS_C 34868 +#define OP_TEMPERATURE 32821 +#define OP_TEMPERATURE_C 34869 +#define OP_TEMPERATURE_E 36917 +#define OP_TEMPERATURE_EC 38965 +#define OP_TEMPERATURE_EC16 38966 +#define OP_TEMPERATURE_E16 36918 +#define OP_SHAPE 32823 +#define OP_SHAPE_C 34871 +#define OP_SHAPE_E 36919 +#define OP_SHAPE_EC 38967 +#define OP_XLOC 32824 +#define OP_XLOC_C 34872 +#define OP_YLOC 32825 +#define OP_YLOC_C 34873 +#define OP_DIR 32826 +#define OP_DIR_C 34874 +#define OP_DIR_E 36922 +#define OP_DIR_EC 38970 +#define OP_IMAGE 32827 +#define OP_IMAGE_C 34875 +#define OP_IMAGE_E 36923 +#define OP_IMAGE_EC 38971 +#define OP_INERTIA 32828 +#define OP_INERTIA_C 34876 +#define OP_INERTIA_E 36924 +#define OP_INERTIA_EC 38972 +#define OP_INERTIA_EC16 38973 +#define OP_INERTIA_E16 36925 +#define OP_DISTANCE 32830 +#define OP_DISTANCE_C 34878 +#define OP_DISTANCE_E 36926 +#define OP_DISTANCE_EC 38974 +#define OP_DISTANCE_EC16 38975 +#define OP_DISTANCE_E16 36927 +#define OP_DENSITY 32832 +#define OP_DENSITY_C 34880 +#define OP_DENSITY_E 36928 +#define OP_DENSITY_EC 38976 +#define OP_DENSITY_EC16 38977 +#define OP_DENSITY_E16 36929 +#define OP_VOLUME 32834 +#define OP_VOLUME_C 34882 +#define OP_VOLUME_E 36930 +#define OP_VOLUME_EC 38978 +#define OP_VOLUME_EC16 38979 +#define OP_VOLUME_E16 36931 +#define OP_WEIGHT 32836 +#define OP_WEIGHT_C 34884 +#define OP_WEIGHT_E 36932 +#define OP_WEIGHT_EC 38980 +#define OP_WEIGHT_EC16 38981 +#define OP_WEIGHT_E16 36933 +#define OP_HEIGHT 32838 +#define OP_HEIGHT_C 34886 +#define OP_HEIGHT_E 36934 +#define OP_HEIGHT_EC 38982 +#define OP_HEIGHT_EC16 38983 +#define OP_HEIGHT_E16 36935 +#define OP_CLIMB 32840 +#define OP_CLIMB_C 34888 +#define OP_CLIMB_E 36936 +#define OP_CLIMB_EC 38984 +#define OP_CLIMB_EC16 38985 +#define OP_CLIMB_E16 36937 +#define OP_STRENGTH 32842 +#define OP_STRENGTH_C 34890 +#define OP_STRENGTH_E 36938 +#define OP_STRENGTH_EC 38986 +#define OP_STRENGTH_EC16 38987 +#define OP_STRENGTH_E16 36939 +#define OP_HARD 32844 +#define OP_HARD_C 34892 +#define OP_HARD_E 36940 +#define OP_HARD_EC 38988 +#define OP_SHARP 32845 +#define OP_SHARP_C 34893 +#define OP_SHARP_E 36941 +#define OP_SHARP_EC 38989 +#define OP_SHAPEDIR 32846 +#define OP_SHAPEDIR_C 34894 +#define OP_SHAPEDIR_E 36942 +#define OP_SHAPEDIR_EC 38990 +#define OP_SHOVABLE 32847 +#define OP_SHOVABLE_C 34895 +#define OP_SHOVABLE_E 36943 +#define OP_SHOVABLE_EC 38991 +#define OP_MISC1 32848 +#define OP_MISC1_C 34896 +#define OP_MISC1_E 36944 +#define OP_MISC1_EC 38992 +#define OP_MISC1_EC16 38993 +#define OP_MISC1_E16 36945 +#define OP_MISC2 32850 +#define OP_MISC2_C 34898 +#define OP_MISC2_E 36946 +#define OP_MISC2_EC 38994 +#define OP_MISC2_EC16 38995 +#define OP_MISC2_E16 36947 +#define OP_MISC3 32852 +#define OP_MISC3_C 34900 +#define OP_MISC3_E 36948 +#define OP_MISC3_EC 38996 +#define OP_MISC3_EC16 38997 +#define OP_MISC3_E16 36949 +#define OP_MISC4 32854 +#define OP_MISC4_C 34902 +#define OP_MISC4_E 36950 +#define OP_MISC4_EC 38998 +#define OP_MISC4_EC16 38999 +#define OP_MISC4_E16 36951 +#define OP_MISC5 32856 +#define OP_MISC5_C 34904 +#define OP_MISC5_E 36952 +#define OP_MISC5_EC 39000 +#define OP_MISC5_EC16 39001 +#define OP_MISC5_E16 36953 +#define OP_MISC6 32858 +#define OP_MISC6_C 34906 +#define OP_MISC6_E 36954 +#define OP_MISC6_EC 39002 +#define OP_MISC6_EC16 39003 +#define OP_MISC6_E16 36955 +#define OP_MISC7 32860 +#define OP_MISC7_C 34908 +#define OP_MISC7_E 36956 +#define OP_MISC7_EC 39004 +#define OP_MISC7_EC16 39005 +#define OP_MISC7_E16 36957 +#define OP_ARRIVED 32862 +#define OP_ARRIVED_C 34910 +#define OP_ARRIVED_E 36958 +#define OP_ARRIVED_EC 39006 +#define OP_DEPARTED 32863 +#define OP_DEPARTED_C 34911 +#define OP_DEPARTED_E 36959 +#define OP_DEPARTED_EC 39007 +#define OP_ARRIVALS 32864 +#define OP_ARRIVALS_C 34912 +#define OP_ARRIVALS_E 36960 +#define OP_ARRIVALS_EC 39008 +#define OP_DEPARTURES 32865 +#define OP_DEPARTURES_C 34913 +#define OP_DEPARTURES_E 36961 +#define OP_DEPARTURES_EC 39009 +#define OP_BUSY 32866 +#define OP_BUSY_C 34914 +#define OP_BUSY_E 36962 +#define OP_BUSY_EC 39010 +#define OP_INVISIBLE 32867 +#define OP_INVISIBLE_C 34915 +#define OP_INVISIBLE_E 36963 +#define OP_INVISIBLE_EC 39011 +#define OP_KEYCLEARED 32868 +#define OP_KEYCLEARED_C 34916 +#define OP_KEYCLEARED_E 36964 +#define OP_KEYCLEARED_EC 39012 +#define OP_USERSIGNAL 32869 +#define OP_USERSIGNAL_C 34917 +#define OP_USERSIGNAL_E 36965 +#define OP_USERSIGNAL_EC 39013 +#define OP_USERSTATE 32870 +#define OP_USERSTATE_C 34918 +#define OP_USERSTATE_E 36966 +#define OP_USERSTATE_EC 39014 +#define OP_VISUALONLY 32871 +#define OP_VISUALONLY_C 34919 +#define OP_VISUALONLY_E 36967 +#define OP_VISUALONLY_EC 39015 +#define OP_STEALTHY 32872 +#define OP_STEALTHY_C 34920 +#define OP_STEALTHY_E 36968 +#define OP_STEALTHY_EC 39016 +#define OP_MOVED 32873 +#define OP_MOVED_C 34921 +#define OP_MOVED_E 36969 +#define OP_MOVED_EC 39017 +#define OP_DONE 32874 +#define OP_DONE_C 34922 +#define OP_DONE_E 36970 +#define OP_DONE_EC 39018 +#define OP_DESTROYED 32875 +#define OP_DESTROYED_C 34923 +#define OP_PLAYER 32876 +#define OP_PLAYER_C 34924 +#define OP_COMPATIBLE 32877 +#define OP_COMPATIBLE_C 34925 +#define OP_COLLISIONLAYERS 32878 +#define OP_COLLISIONLAYERS_C 34926 +#define OP_SELF 32879 +#define OP_MSG 32880 +#define OP_FROM 32881 +#define OP_ARG1 32882 +#define OP_ARG1_E 36978 +#define OP_ARG2 32883 +#define OP_ARG2_E 36979 +#define OP_ARG3 32884 +#define OP_ARG3_E 36980 +#define OP_MOVENUMBER 32885 +#define OP_LEVEL 32886 +#define OP_KEY 32887 +#define OP_BACKGROUND 32888 +#define OP_INPUT 32889 +#define OP_QUIZ 32890 +#define OP_INPLACE 32891 +#define OP_DEFAULTIMAGE 32892 +#define OP_HELP 32893 +#define OP_EDITORHELP 32894 +#define OP_SUBS 32895 +#define OP_ANIMATE 32896 +#define OP_ASSASSINATE 32897 +#define OP_ASSASSINATE_C 34945 +#define OP_BROADCAST 32898 +#define OP_BROADCAST_D 41090 +#define OP_BROADCASTCLASS 32899 +#define OP_BROADCASTEX 32900 +#define OP_BROADCASTEX_D 41092 +#define OP_BROADCASTSUM 32901 +#define OP_BROADCASTSUMEX 32902 +#define OP_CREATE 32903 +#define OP_CREATE_D 41095 +#define OP_DELINVENTORY 32904 +#define OP_DELTA 32905 +#define OP_DESTROY 32906 +#define OP_DESTROY_C 34954 +#define OP_DESTROY_D 41098 +#define OP_DESTROY_CD 43146 +#define OP_FLUSHCLASS 32907 +#define OP_FLUSHOBJ 32908 +#define OP_FLUSHOBJ_C 34956 +#define OP_GETINVENTORY 32909 +#define OP_HEIGHTAT 32910 +#define OP_IGNOREKEY 32911 +#define OP_INTMOVE 32912 +#define OP_INTMOVE_C 34960 +#define OP_INTMOVE_D 41104 +#define OP_INTMOVE_CD 43152 +#define OP_JUMPTO 32913 +#define OP_JUMPTO_C 34961 +#define OP_JUMPTO_D 41105 +#define OP_JUMPTO_CD 43153 +#define OP_LOC 32914 +#define OP_LOC_C 34962 +#define OP_LOCATEME 32915 +#define OP_LOSELEVEL 32916 +#define OP_MAXINVENTORY 32917 +#define OP_MOVE 32918 +#define OP_MOVE_C 34966 +#define OP_MOVE_D 41110 +#define OP_MOVE_CD 43158 +#define OP_MOVEPLUS 32919 +#define OP_MOVEPLUS_C 34967 +#define OP_MOVEPLUS_D 41111 +#define OP_MOVEPLUS_CD 43159 +#define OP_MOVETO 32920 +#define OP_MOVETO_C 34968 +#define OP_MOVETO_D 41112 +#define OP_MOVETO_CD 43160 +#define OP_NEWX 32921 +#define OP_NEWY 32922 +#define OP_OBJABOVE 32923 +#define OP_OBJABOVE_C 34971 +#define OP_OBJBELOW 32924 +#define OP_OBJBELOW_C 34972 +#define OP_OBJBOTTOMAT 32925 +#define OP_OBJCLASSAT 32926 +#define OP_OBJDIR 32927 +#define OP_OBJDIR_C 34975 +#define OP_OBJLAYERAT 32928 +#define OP_OBJTOPAT 32929 +#define OP_POPUP 32930 +#define OP_POPUPARGS 32931 +#define OP_QUEUETURN 32932 +#define OP_SEND 32933 +#define OP_SEND_C 34981 +#define OP_SEND_D 41125 +#define OP_SEND_CD 43173 +#define OP_SENDEX 32934 +#define OP_SENDEX_C 34982 +#define OP_SENDEX_D 41126 +#define OP_SENDEX_CD 43174 +#define OP_SETINVENTORY 32935 +#define OP_SOUND 32936 +#define OP_SYNCHRONIZE 32937 +#define OP_TRACE 32938 +#define OP_VOLUMEAT 32939 +#define OP_WINLEVEL 32940 +#define OP_XDIR 32941 +#define OP_XDIR_C 34989 +#define OP_YDIR 32942 +#define OP_YDIR_C 34990 +#define OP_FUNCTION 32943 +#define OP_LOCAL 32944 +#define OP_LABEL 32945 +#define OP_STRING 32946 +#define OP_INT16 32947 +#define OP_INT32 32948 #ifdef HEROMESH_CLASS static const Op_Names op_names[]={ {"*",8486935}, {"+",8421397}, {"-",8421398}, @@ -366,17 +373,17 @@ {"-rot",8421382}, {".",10518528}, {"/",8486936}, {"ANHH",8389394}, {"ARRIVED",8389124}, -{"Animate",8421497}, -{"Arg1",8552555}, -{"Arg2",8552556}, -{"Arg3",8552557}, -{"Arrivals",8618073}, -{"Arrived",8618071}, -{"Assassinate",8487034}, +{"Animate",8421504}, +{"Arg1",8552562}, +{"Arg2",8552563}, +{"Arg3",8552564}, +{"Arrivals",8618080}, +{"Arrived",8618078}, +{"Assassinate",8487041}, {"B",9437196}, {"BANG",8389380}, {"BEDOINGNG",8389406}, {"BEEDEEP",8389404}, {"BEGIN_TURN",8389123}, @@ -385,137 +392,137 @@ {"BOUNCE",8389415}, {"BRRREEET",8389396}, {"BRRRT",8389395}, {"BUZZER",8389420}, {"BWEEP",8389397}, -{"Background",8683633}, -{"Broadcast",10518651}, -{"BroadcastEx",10518653}, -{"BroadcastSum",8421502}, -{"BroadcastSumEx",8421503}, -{"Busy",8618075}, +{"Background",8683640}, +{"Broadcast",10518658}, +{"BroadcastEx",10518660}, +{"BroadcastSum",8421509}, +{"BroadcastSumEx",8421510}, +{"Busy",8618082}, {"CHEEP",8389393}, {"CHYEW",8389392}, {"CLEANUP",8389140}, {"CLICK",8389388}, {"COLLIDE",8389142}, {"COLLIDEBY",8389141}, {"CREATE",8389121}, {"CREATED",8389137}, -{"Class",8486957}, -{"Climb",9142337}, -{"CollisionLayers",8487015}, -{"Compatible",8487014}, -{"Create",10518656}, +{"Class",8486964}, +{"Climb",9142344}, +{"CollisionLayers",8487022}, +{"Compatible",8487021}, +{"Create",10518663}, {"DEEP_POP",8389417}, {"DEPARTED",8389125}, {"DESTROY",8389122}, {"DESTROYED",8389136}, {"DINK",8389390}, {"DOOR",8389378}, {"DRLRLRINK",8389398}, {"DYUPE",8389413}, -{"DefaultImage",8683637}, -{"DelInventory",8421505}, -{"Delta",8421506}, -{"Density",9142329}, -{"Departed",8618072}, -{"Departures",8618074}, -{"Destroy",10584195}, -{"Destroyed",8487012}, -{"Dir",8618035}, -{"Distance",9142327}, -{"Done",8618083}, +{"DefaultImage",8683644}, +{"DelInventory",8421512}, +{"Delta",8421513}, +{"Density",9142336}, +{"Departed",8618079}, +{"Departures",8618081}, +{"Destroy",10584202}, +{"Destroyed",8487019}, +{"Dir",8618042}, +{"Distance",9142334}, +{"Done",8618090}, {"E",9437184}, {"END_TURN",8389139}, -{"EditorHelp",8683639}, +{"EditorHelp",8683646}, {"F",9437192}, {"FAROUT",8389421}, {"FFFFTT",8389399}, {"FLOATED",8389132}, {"FROG",8389383}, -{"FlushClass",8421508}, -{"FlushObj",8487045}, -{"From",8421482}, +{"FlushClass",8421515}, +{"FlushObj",8487052}, +{"From",8421489}, {"GLASS",8389379}, {"GLISSANT",8389419}, -{"GetInventory",8421510}, +{"GetInventory",8421517}, {"HAWK",8389425}, {"HEARTBEAT",8389407}, {"HIT",8389134}, {"HITBY",8389135}, -{"Hard",8618053}, -{"Height",9142335}, -{"HeightAt",8421511}, -{"Help",8683638}, +{"Hard",8618060}, +{"Height",9142342}, +{"HeightAt",8421518}, +{"Help",8683645}, {"INIT",8389120}, -{"IgnoreKey",8421512}, -{"Image",8618036}, -{"InPlace",8683636}, -{"Inertia",9142325}, -{"Input",8683634}, -{"IntMove",10584201}, -{"Invisible",8618076}, +{"IgnoreKey",8421519}, +{"Image",8618043}, +{"InPlace",8683643}, +{"Inertia",9142332}, +{"Input",8683641}, +{"IntMove",10584208}, +{"Invisible",8618083}, {"JAYAYAYNG",8389416}, {"JUMPED",8389128}, -{"JumpTo",10584202}, +{"JumpTo",10584209}, {"KEWEL",8389422}, {"KEY",8389129}, {"KLECK",8389387}, {"KLINKK",8389385}, -{"Key",8421488}, -{"KeyCleared",8618077}, +{"Key",8421495}, +{"KeyCleared",8618084}, {"L",9437194}, {"LASTIMAGE",8389126}, {"LB",9437195}, {"LF",9437193}, {"LOCK",8389408}, {"LOOP",8388610}, -{"Level",8421487}, -{"Loc",8487051}, -{"LocateMe",8421516}, -{"LoseLevel",8421517}, +{"Level",8421494}, +{"Loc",8487058}, +{"LocateMe",8421523}, +{"LoseLevel",8421524}, {"MOVED",8389127}, {"MOVING",8389130}, -{"MaxInventory",8421518}, -{"Misc1",9142345}, -{"Misc2",9142347}, -{"Misc3",9142349}, -{"Misc4",9142351}, -{"Misc5",9142353}, -{"Misc6",9142355}, -{"Misc7",9142357}, -{"Move",10584207}, -{"Move+",10584208}, -{"MoveNumber",8421486}, -{"MoveTo",10584209}, -{"Moved",8618082}, -{"Msg",8421481}, +{"MaxInventory",8421525}, +{"Misc1",9142352}, +{"Misc2",9142354}, +{"Misc3",9142356}, +{"Misc4",9142358}, +{"Misc5",9142360}, +{"Misc6",9142362}, +{"Misc7",9142364}, +{"Move",10584214}, +{"Move+",10584215}, +{"MoveNumber",8421493}, +{"MoveTo",10584216}, +{"Moved",8618089}, +{"Msg",8421488}, {"N",9437186}, {"NE",9437185}, {"NW",9437187}, -{"NewX",8421522}, -{"NewY",8421523}, +{"NewX",8421529}, +{"NewY",8421530}, {"OLDPHONE",8389402}, {"ONCE",8388609}, {"OSC",8388616}, {"OSCLOOP",8388618}, -{"ObjAbove",8487060}, -{"ObjBelow",8487061}, -{"ObjBottomAt",8421526}, -{"ObjClassAt",8421527}, -{"ObjDir",8487064}, -{"ObjLayerAt",8421529}, -{"ObjTopAt",8421530}, +{"ObjAbove",8487067}, +{"ObjBelow",8487068}, +{"ObjBottomAt",8421533}, +{"ObjClassAt",8421534}, +{"ObjDir",8487071}, +{"ObjLayerAt",8421536}, +{"ObjTopAt",8421537}, {"PLAYERMOVING",8389133}, {"POSTINIT",8389138}, {"POUR",8389377}, {"POWER",8389386}, -{"Player",8487013}, -{"PopUp",8421531}, -{"QueueTurn",8421533}, -{"Quiz",8683635}, +{"Player",8487020}, +{"PopUp",8421538}, +{"QueueTurn",8421540}, +{"Quiz",8683642}, {"R",9437198}, {"RATCHET1",8389418}, {"RATCHET2",8389412}, {"RATTLE",8389403}, {"RB",9437197}, @@ -524,50 +531,50 @@ {"SE",9437191}, {"SMALL_POP",8389389}, {"SPLASH",8389376}, {"STEAM",8389424}, {"STOP",8388608}, -{"SUBS",8683640}, +{"SUBS",8683647}, {"SUNK",8389131}, {"SW",9437189}, -{"Self",8421480}, -{"Send",10584222}, -{"SendEx",10584223}, -{"SetInventory",8421536}, -{"Shape",8618032}, -{"ShapeDir",8618055}, -{"Sharp",8618054}, -{"Shovable",8618056}, -{"Sound",8421537}, -{"Stealthy",8618081}, -{"Strength",9142339}, -{"Synchronize",8421538}, +{"Self",8421487}, +{"Send",10584229}, +{"SendEx",10584230}, +{"SetInventory",8421543}, +{"Shape",8618039}, +{"ShapeDir",8618062}, +{"Sharp",8618061}, +{"Shovable",8618063}, +{"Sound",8421544}, +{"Stealthy",8618088}, +{"Strength",9142346}, +{"Synchronize",8421545}, {"TAHTASHH",8389409}, {"THMP_thmp",8389405}, {"THWIT",8389384}, {"TICK",8389391}, -{"Temperature",9142318}, -{"Trace",8421539}, +{"Temperature",9142325}, +{"Trace",8421546}, {"UH_OH",8389382}, {"UNCORK",8389414}, {"UNHH",8389381}, -{"UserSignal",8618078}, -{"UserState",8618079}, +{"UserSignal",8618085}, +{"UserState",8618086}, {"VACUUM",8389411}, -{"VisualOnly",8618080}, -{"Volume",9142331}, -{"VolumeAt",8421540}, +{"VisualOnly",8618087}, +{"Volume",9142338}, +{"VolumeAt",8421547}, {"W",9437188}, {"WAHOO",8389400}, {"WHACK",8389423}, -{"Weight",9142333}, -{"WinLevel",8421541}, -{"XDir",8487078}, -{"Xloc",8486961}, -{"YDir",8487079}, +{"Weight",9142340}, +{"WinLevel",8421548}, +{"XDir",8487085}, +{"Xloc",8486968}, +{"YDir",8487086}, {"YEEHAW",8389401}, -{"Yloc",8486962}, +{"Yloc",8486969}, {"again",8683532}, {"band",8421405}, {"begin",8683531}, {"bit",8683553}, {"bit0",8388609}, @@ -603,10 +610,12 @@ {"bit8",8423400}, {"bit9",8423401}, {"bnot",8421408}, {"bor",8421406}, {"bxor",8421407}, +{"c?",8421422}, +{"cz?",8421423}, {"dup",8486913}, {"el",8683530}, {"else",8683528}, {"eq",8421414}, {"for",8683536}, @@ -619,22 +628,27 @@ {"lnot",8421413}, {"lor",8421411}, {"lsh",8421403}, {"lt",8486953}, {"lxor",8421412}, +{"m?",8421424}, {"mod",8486937}, +{"n?",8421421}, {"ne",8421415}, {"neg",8421402}, {"next",8683537}, {"nip",8421379}, +{"o?",8421426}, +{"oz?",8421427}, {"repeat",8683535}, {"ret",8421396}, {"rot",8421381}, {"rsh",8486940}, +{"s?",8421425}, {"swap",8421378}, {"then",8683529}, {"tuck",8421380}, {"until",8683533}, {"while",8683534}, }; -#define N_OP_NAMES 275 +#define N_OP_NAMES 282 #endif