Subversion Repositories nw_plus

Rev

Rev 52 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 52 Rev 66
Line 7... Line 7...
7
Duke: Nuclear Winter Plus
7
Duke: Nuclear Winter Plus
8
By Hendricks266
8
By Hendricks266
9
--------------------------------------------------------------------------------
9
--------------------------------------------------------------------------------
10
*/
10
*/
11
 
11
 
12
definecheat 14 endepisode
-
 
13
definecheat 15 endlevel
-
 
14
definecheat 25 endvolume
-
 
15
 
-
 
16
include NWDefs.con
12
include NWDefs.con
17
include NWUser.con
13
include NWUser.con
18
 
14
 
19
setgamename Duke: Nuclear Winter
15
setgamename Duke: Nuclear Winter
20
 
16
 
21
gamevar picnum 0 2
17
gamevar nw_picnum 0 2
22
gamevar temp 0 2
18
gamevar nw_temp 0 2
23
gamevar tempb 0 2
19
gamevar nw_tempb 0 2
24
gamevar x 0 2
20
gamevar nw_x 0 2
25
gamevar y 0 2
21
gamevar nw_y 0 2
26
gamevar z 0 2
22
gamevar nw_z 0 2
27
 
23
 
28
gamevar owner 0 2
24
gamevar nw_owner 0 2
29
gamevar temp2 0 2
25
gamevar nw_temp2 0 2
30
gamevar temp3 0 2
26
gamevar nw_temp3 0 2
31
gamevar temp4 0 2
27
// gamevar nw_temp4 0 0
32
gamevar ptemp 0 1
28
// gamevar nw_ptemp 0 1
33
gamevar holodukeid 0 1
29
gamevar nw_holodukeid 0 1
34
gamevar musicchange 0 1
30
gamevar nw_musicchange 0 1
35
gamevar skin DUKE 132097 // do not reset flag enabled
31
gamevar skin DUKE 132097 // do not reset flag enabled
36
 
32
 
37
gamevar LOGO_FLAGS 767 0 // default; TEN screen reenabled
33
gamevar LOGO_FLAGS 767 0 // default; TEN screen reenabled
38
 
34
 
39
state cutsceneambience
35
state cutsceneambience
40
  getactor[THISACTOR].lotag temp
36
  getactor[THISACTOR].lotag nw_temp
41
 
37
 
42
  switch temp
38
  switch nw_temp
43
 
39
 
44
    case WIND_AMBIENCE
40
    case WIND_AMBIENCE
45
    case WIND_REPEAT
41
    case WIND_REPEAT
46
     setactor[THISACTOR].lotag WIND2
42
     setactor[THISACTOR].lotag WIND2
47
    break
43
    break
Line 52... Line 48...
52
 
48
 
53
  endswitch
49
  endswitch
54
ends
50
ends
55
 
51
 
56
onevent EVENT_LOADACTOR
52
onevent EVENT_LOADACTOR
57
  getactor[THISACTOR].picnum picnum
53
  getactor[THISACTOR].picnum nw_picnum
58
  switch picnum
54
  switch nw_picnum
59
 
55
 
60
   case SNOWYDOORSHOCK 
56
   case SNOWYDOORSHOCK 
61
     spritepal 30
57
     spritepal 30
62
     cactor DOORSHOCK
58
     cactor DOORSHOCK
63
   break
59
   break
Line 77... Line 73...
77
   case MUSICANDSFX
73
   case MUSICANDSFX
78
     state cutsceneambience
74
     state cutsceneambience
79
   break
75
   break
80
 
76
 
81
   case JETPACK
77
   case JETPACK
82
     ifspritepal 21 setvar temp 1
78
     ifspritepal 21 setvar nw_temp 1
83
     spritepal 0
79
     spritepal 0
84
   break
80
   break
85
 
81
 
86
/*
82
/*
87
   case SNOWFLAKE
83
   case SNOWFLAKE
Line 90... Line 86...
90
   break
86
   break
91
*/
87
*/
92
 
88
 
93
   case XMASPRESENT
89
   case XMASPRESENT
94
   case XMASPRESENT2
90
   case XMASPRESENT2
95
     getactor[THISACTOR].hitag temp
91
     getactor[THISACTOR].hitag nw_temp
96
     setactor[THISACTOR].hitag 0
92
     setactor[THISACTOR].hitag 0
97
   break
93
   break
98
 
94
 
99
  endswitch
95
  endswitch
100
endevent
96
endevent
101
 
97
 
102
onevent EVENT_SPAWN
98
onevent EVENT_SPAWN
103
  getactor[THISACTOR].owner owner
99
  getactor[THISACTOR].owner nw_owner
104
  getactor[THISACTOR].picnum picnum
100
  getactor[THISACTOR].picnum nw_picnum
105
endevent
101
endevent
106
 
102
 
107
onevent EVENT_EGS
103
onevent EVENT_EGS
108
 getactor[THISACTOR].picnum picnum
104
 getactor[THISACTOR].picnum nw_picnum
109
 
105
 
110
 ifactor APLAYER setactor[THISACTOR].mdflags 16
106
 ifactor APLAYER setactor[THISACTOR].mdflags 16
111
 ifactor DUKETORSO setactor[THISACTOR].mdflags 16
107
 ifactor DUKETORSO setactor[THISACTOR].mdflags 16
112
 ifactor DUKEGUN setactor[THISACTOR].mdflags 16
108
 ifactor DUKEGUN setactor[THISACTOR].mdflags 16
113
 ifactor DUKELEG setactor[THISACTOR].mdflags 16
109
 ifactor DUKELEG setactor[THISACTOR].mdflags 16
Line 115... Line 111...
115
 
111
 
116
 ifactor SNOW
112
 ifactor SNOW
117
   {
113
   {
118
     sizeat 8 8
114
     sizeat 8 8
119
 
115
 
120
     setvar temp3 0
116
     setvar nw_temp3 0
121
     randvar temp3 2047
117
     randvar nw_temp3 2047
122
     setactor[THISACTOR].ang temp3
118
     setactor[THISACTOR].ang nw_temp3
123
 
119
 
124
     setvar temp2 -2047
120
     setvar nw_temp2 -2047
125
     randvar temp2 2047
121
     randvar nw_temp2 2047
126
 
122
 
127
/*
123
/*
128
     setvar temp3 0
124
     setvar nw_temp3 0
129
     ifrnd 128 addvar temp3 4
125
     ifrnd 128 addvar nw_temp3 4
130
     ifrnd 128 addvar temp3 8
126
     ifrnd 128 addvar nw_temp3 8
131
     setactor[THISACTOR].cstat temp3
127
     setactor[THISACTOR].cstat nw_temp3
132
*/
128
*/
133
   }
129
   }
134
endevent
130
endevent
135
 
131
 
136
// -----------------------------------------------------------------------------
132
// -----------------------------------------------------------------------------
Line 272... Line 268...
272
        ifpdistl RETRIEVEDISTANCE
268
        ifpdistl RETRIEVEDISTANCE
273
          ifcount 6
269
          ifcount 6
274
            ifpinventory GET_JETPACK JETPACK_AMOUNT
270
            ifpinventory GET_JETPACK JETPACK_AMOUNT
275
              ifcanseetarget
271
              ifcanseetarget
276
      {
272
      {
277
        ifvare temp 1
273
        ifvare nw_temp 1
278
        {
274
        {
279
          addinventory GET_JETPACK JETPACK_NEAR_EMPTY
275
          addinventory GET_JETPACK JETPACK_NEAR_EMPTY
-
 
276
          redefinequote 122       This jetpack is almost empty!
280
          quote 125
277
          quote 122
281
        }
278
        }
282
        else
279
        else
283
        {
280
        {
284
          addinventory GET_JETPACK JETPACK_AMOUNT
281
          addinventory GET_JETPACK JETPACK_AMOUNT
285
          quote 41
282
          quote 41
Line 296... Line 293...
296
action FEMHDANCE2 206 2 1 1 10
293
action FEMHDANCE2 206 2 1 1 10
297
 
294
 
298
 
295
 
299
 
296
 
300
state nwbabecode
297
state nwbabecode
301
 getactor[THISACTOR].cstat temp
298
 getactor[THISACTOR].cstat nw_temp
302
 ifvarand temp 1 nullop else addvar temp 1
299
 ifvarand nw_temp 1 nullop else addvar nw_temp 1
303
 ifactor HALFBITCH { ifvarand temp 128 nullop else addvar temp 128 }
300
 ifactor HALFBITCH { ifvarand nw_temp 128 nullop else addvar nw_temp 128 }
304
 ifvarand temp 256 nullop else addvar temp 256
301
 ifvarand nw_temp 256 nullop else addvar nw_temp 256
305
 
302
 
306
 getuserdef .lockout temp2
303
 getuserdef .lockout nw_temp2
307
 ifvare temp2 1
304
 ifvare nw_temp2 1
308
   {
305
   {
309
     ifvarand temp 32768 nullop else addvar temp 32768
306
     ifvarand nw_temp 32768 nullop else addvar nw_temp 32768
310
   }
307
   }
311
 else
308
 else
312
  // {
309
  // {
313
     ifvarand temp 32768 subvar temp 32768
310
     ifvarand nw_temp 32768 subvar nw_temp 32768
314
  // }
311
  // }
315
 
312
 
316
 setactor[THISACTOR].cstat temp
313
 setactor[THISACTOR].cstat nw_temp
317
 
314
 
318
 
315
 
319
 
316
 
320
  ifactor HALFBITCH nullop else fall
317
  ifactor HALFBITCH nullop else fall
321
 
318
 
Line 554... Line 551...
554
state nwl3surprise
551
state nwl3surprise
555
ifvare VOLUME 1
552
ifvare VOLUME 1
556
  {
553
  {
557
    ifvare LEVEL 2
554
    ifvare LEVEL 2
558
      {
555
      {
559
        getactor[THISACTOR].sectnum temp
556
        getactor[THISACTOR].sectnum nw_temp
560
        switch temp
557
        switch nw_temp
561
          case 220 case 221
558
          case 220 case 221
562
            ifvarn musicchange 1
559
            ifvarn nw_musicchange 1
563
              {
560
              {
564
                starttrack 12 // doom
561
                starttrack 12 // doom
565
                setvar musicchange 1
562
                setvar nw_musicchange 1
566
              }
563
              }
567
          break
564
          break
568
          case 563 case 564 case 565 case 566 case 567
565
          case 563 case 564 case 565 case 566 case 567
569
            ifvarn musicchange 2
566
            ifvarn nw_musicchange 2
570
              {
567
              {
571
                starttrack 13 // mario
568
                starttrack 13 // mario
572
                setvar musicchange 2
569
                setvar nw_musicchange 2
573
              }
570
              }
574
          break
571
          break
575
          case 192 case 193 case 194 case 195 case 196 case 197 case 198 case 237 case 238 case 239 case 240
572
          case 192 case 193 case 194 case 195 case 196 case 197 case 198 case 237 case 238 case 239 case 240
576
          case 166 case 167 case 172 case 173 case 174 case 176 case 179
573
          case 166 case 167 case 172 case 173 case 174 case 176 case 179
577
            ifvarn musicchange 0
574
            ifvarn nw_musicchange 0
578
              {
575
              {
579
                starttrackvar LEVEL // level music
576
                starttrackvar LEVEL // level music
580
                setvar musicchange 0
577
                setvar nw_musicchange 0
581
              }
578
              }
582
          break
579
          break
583
        endswitch
580
        endswitch
584
      }
581
      }
585
  }
582
  }
Line 779... Line 776...
779
      {
776
      {
780
        shoot FREEZEBLAST
777
        shoot FREEZEBLAST
781
        resetactioncount
778
        resetactioncount
782
      }
779
      }
783
 
780
 
784
      getplayer[THISACTOR].i temp
781
      getplayer[THISACTOR].i nw_temp
785
      getactor[temp].pal temp
782
      getactor[nw_temp].pal nw_temp
786
      ifvare temp 1 // if player is frozen
783
      ifvare nw_temp 1 // if player is frozen
787
        ai AICOMMGET
784
        ai AICOMMGET
788
    }
785
    }
789
    else
786
    else
790
      ai AICOMMGET
787
      ai AICOMMGET
791
  }
788
  }
Line 816... Line 813...
816
        sound COMM_SPIN
813
        sound COMM_SPIN
817
        ai AICOMMSPINNW
814
        ai AICOMMSPINNW
818
        break
815
        break
819
      }
816
      }
820
      
817
      
821
      getplayer[THISACTOR].i temp
818
      getplayer[THISACTOR].i nw_temp
822
      getactor[temp].pal temp
819
      getactor[nw_temp].pal nw_temp
823
      ifvare temp 1 // if player is frozen
820
      ifvare nw_temp 1 // if player is frozen
824
      {
821
      {
825
        sound COMM_SPIN
822
        sound COMM_SPIN
826
        ai AICOMMSPINNW
823
        ai AICOMMSPINNW
827
        break
824
        break
828
      }
825
      }
Line 845... Line 842...
845
    soundonce COMM_SPIN
842
    soundonce COMM_SPIN
846
    ifcount 16
843
    ifcount 16
847
    {
844
    {
848
      ifpdistl 1280
845
      ifpdistl 1280
849
      {
846
      {
850
        setvar tempb CAPTSPINNINGPLAYER
847
        setvar nw_tempb CAPTSPINNINGPLAYER
851
        mulvar tempb -1
848
        mulvar nw_tempb -1
852
        // addphealth CAPTSPINNINGPLAYER
849
        // addphealth CAPTSPINNINGPLAYER
853
        getplayer[THISACTOR].i temp
850
        getplayer[THISACTOR].i nw_temp
854
        setactor[temp].htextra tempb
851
        setactor[nw_temp].htextra nw_tempb
855
        setactor[temp].htpicnum KNEE
852
        setactor[nw_temp].htpicnum KNEE
856
        setactor[temp].htowner THISACTOR
853
        setactor[nw_temp].htowner THISACTOR
857
 
854
 
858
        globalsound DUKE_GRUNT
855
        globalsound DUKE_GRUNT
859
        palfrom 32 16
856
        palfrom 32 16
860
        resetcount
857
        resetcount
861
      }
858
      }
Line 1034... Line 1031...
1034
onevent EVENT_GAME
1031
onevent EVENT_GAME
1035
  ifactor APLAYER
1032
  ifactor APLAYER
1036
  {
1033
  {
1037
    state nwl3surprise
1034
    state nwl3surprise
1038
    
1035
    
1039
    getplayer[THISACTOR].holoduke_on holodukeid
1036
    getplayer[THISACTOR].holoduke_on nw_holodukeid
1040
    ifvarg holodukeid -1
1037
    ifvarg nw_holodukeid -1
1041
      setactor[holodukeid].mdflags 16
1038
      setactor[nw_holodukeid].mdflags 16
1042
    
1039
    
1043
   // addlogvar skin
1040
   // addlogvar skin
1044
  }
1041
  }
1045
  ifactor FRAMEEFFECT1
1042
  ifactor FRAMEEFFECT1
1046
    ifspawnedby APLAYER
1043
    ifspawnedby APLAYER
Line 1048... Line 1045...
1048
 
1045
 
1049
/*
1046
/*
1050
  ifactor MONEY
1047
  ifactor MONEY
1051
    {
1048
    {
1052
      setactor[THISACTOR].mdflags 16
1049
      setactor[THISACTOR].mdflags 16
1053
      // getactor[THISACTOR].owner owner
1050
      // getactor[THISACTOR].owner nw_owner
1054
      switch owner
1051
      switch nw_owner
1055
      case SNOW case SNOWFLAKE case SNOWMAKER case SNOWMAKERNOMOVE
1052
      case SNOW case SNOWFLAKE case SNOWMAKER case SNOWMAKERNOMOVE
1056
        getactor[THISACTOR].x x
1053
        getactor[THISACTOR].x nw_x
1057
        getactor[THISACTOR].y y
1054
        getactor[THISACTOR].y nw_y
1058
        getactor[THISACTOR].z z
1055
        getactor[THISACTOR].z nw_z
1059
 
1056
 
1060
        updatesectorz x y z temp
1057
        updatesectorz nw_x nw_y nw_z nw_temp
1061
        ifvarn temp -1 getflorzofslope temp x y temp2 else killit
1058
        ifvarn nw_temp -1 getflorzofslope nw_temp nw_x nw_y nw_temp2 else killit
1062
 
1059
 
1063
        ifvarvare z temp2 killit
1060
        ifvarvare nw_z nw_temp2 killit
1064
      break
1061
      break
1065
      endswitch
1062
      endswitch
1066
    }
1063
    }
1067
*/
1064
*/
1068
endevent
1065
endevent
1069
 
1066
 
1070
onevent EVENT_ANIMATESPRITES
1067
onevent EVENT_ANIMATESPRITES
1071
 
1068
 
1072
 ifvare picnum DOORSHOCK
1069
 ifvare nw_picnum DOORSHOCK
1073
   {
1070
   {
1074
     ifspritepal 30 settspr[THISACTOR].tsprpicnum 3656
1071
     ifspritepal 30 settspr[THISACTOR].tsprpicnum 3656
1075
     ifvare VOLUME 1 ifvare LEVEL 2 settspr[THISACTOR].tsprpicnum 3656
1072
     ifvare VOLUME 1 ifvare LEVEL 2 settspr[THISACTOR].tsprpicnum 3656
1076
     break
1073
     break
1077
   }
1074
   }
1078
 ifvare picnum SNOWFLAKE
1075
 ifvare nw_picnum SNOWFLAKE
1079
   {
1076
   {
1080
     settspr[THISACTOR].tsprpicnum SNOW
1077
     settspr[THISACTOR].tsprpicnum SNOW
1081
     settspr[THISACTOR].tsprxrepeat 4
1078
     settspr[THISACTOR].tsprxrepeat 4
1082
     settspr[THISACTOR].tspryrepeat 4
1079
     settspr[THISACTOR].tspryrepeat 4
1083
     break
1080
     break
1084
   }
1081
   }
1085
/*
1082
/*
1086
 ifvare picnum MONEY
1083
 ifvare nw_picnum MONEY
1087
   {
1084
   {
1088
      switch owner
1085
      switch nw_owner
1089
      case SNOW case SNOWFLAKE case SNOWMAKER case SNOWMAKERNOMOVE
1086
      case SNOW case SNOWFLAKE case SNOWMAKER case SNOWMAKERNOMOVE
1090
        settspr[THISACTOR].tsprpicnum SNOW
1087
        settspr[THISACTOR].tsprpicnum SNOW
1091
      break
1088
      break
1092
      endswitch
1089
      endswitch
1093
   }
1090
   }
1094
*/
1091
*/
1095
 
1092
 
1096
  switch picnum
1093
  switch nw_picnum
1097
    case APLAYER
1094
    case APLAYER
1098
      ifvare skin SANTA
1095
      ifvare skin SANTA
1099
      {
1096
      {
1100
        gettspr[THISACTOR].tsprpicnum temp3
1097
        gettspr[THISACTOR].tsprpicnum nw_temp3
1101
        ifvarg temp3 1399 ifvarl temp3 1544 addvar temp3 4096
1098
        ifvarg nw_temp3 1399 ifvarl nw_temp3 1544 addvar nw_temp3 4096
1102
        settspr[THISACTOR].tsprpicnum temp3
1099
        settspr[THISACTOR].tsprpicnum nw_temp3
1103
 
1100
 
1104
        ifvarg holodukeid -1
1101
        ifvarg nw_holodukeid -1
1105
        {
1102
        {
1106
          gettspr[holodukeid].tsprpicnum temp3
1103
          gettspr[nw_holodukeid].tsprpicnum nw_temp3
1107
          ifvarg temp3 1399 ifvarl temp3 1544 addvar temp3 4096
1104
          ifvarg nw_temp3 1399 ifvarl nw_temp3 1544 addvar nw_temp3 4096
1108
          settspr[holodukeid].tsprpicnum temp3
1105
          settspr[nw_holodukeid].tsprpicnum nw_temp3
1109
        }
1106
        }
1110
      }
1107
      }
1111
      break
1108
      break
1112
 
1109
 
1113
    case FRAMEEFFECT1
1110
    case FRAMEEFFECT1
1114
      ifvare skin SANTA
1111
      ifvare skin SANTA
1115
        ifspawnedby APLAYER
1112
        ifspawnedby APLAYER
1116
        {
1113
        {
1117
          gettspr[THISACTOR].tsprpicnum temp3
1114
          gettspr[THISACTOR].tsprpicnum nw_temp3
1118
          ifvarg temp3 1399 ifvarl temp3 1544 addvar temp3 4096
1115
          ifvarg nw_temp3 1399 ifvarl nw_temp3 1544 addvar nw_temp3 4096
1119
          settspr[THISACTOR].tsprpicnum temp3
1116
          settspr[THISACTOR].tsprpicnum nw_temp3
1120
        }
1117
        }
1121
      break
1118
      break
1122
 
1119
 
1123
    case DUKETORSO
1120
    case DUKETORSO
1124
    case DUKEGUN
1121
    case DUKEGUN
1125
      getactor[owner].picnum temp2
1122
      getactor[nw_owner].picnum nw_temp2
1126
      ifvare temp2 SOBBOTWALK
1123
      ifvare nw_temp2 SOBBOTWALK
1127
      {
1124
      {
1128
        gettspr[THISACTOR].tsprpicnum temp3
1125
        gettspr[THISACTOR].tsprpicnum nw_temp3
1129
        addvar temp3 2456
1126
        addvar nw_temp3 2456
1130
        settspr[THISACTOR].tsprpicnum temp3
1127
        settspr[THISACTOR].tsprpicnum nw_temp3
1131
      }
1128
      }
1132
      ifvare temp2 SOBBOTFLY
1129
      ifvare nw_temp2 SOBBOTFLY
1133
      {
1130
      {
1134
        gettspr[THISACTOR].tsprpicnum temp3
1131
        gettspr[THISACTOR].tsprpicnum nw_temp3
1135
        addvar temp3 2456
1132
        addvar nw_temp3 2456
1136
        settspr[THISACTOR].tsprpicnum temp3
1133
        settspr[THISACTOR].tsprpicnum nw_temp3
1137
      }
1134
      }
1138
      ifvare temp2 APLAYER
1135
      ifvare nw_temp2 APLAYER
1139
      {
1136
      {
1140
        ifvare skin SANTA
1137
        ifvare skin SANTA
1141
        {
1138
        {
1142
          gettspr[THISACTOR].tsprpicnum temp3
1139
          gettspr[THISACTOR].tsprpicnum nw_temp3
1143
          addvar temp3 2456
1140
          addvar nw_temp3 2456
1144
          settspr[THISACTOR].tsprpicnum temp3
1141
          settspr[THISACTOR].tsprpicnum nw_temp3
1145
        }
1142
        }
1146
      }
1143
      }
1147
      break
1144
      break
1148
 
1145
 
1149
    case DUKELEG
1146
    case DUKELEG
1150
      getactor[owner].picnum temp2
1147
      getactor[nw_owner].picnum nw_temp2
1151
      ifvare temp2 SOBBOTWALK settspr[THISACTOR].tsprpal 30
1148
      ifvare nw_temp2 SOBBOTWALK settspr[THISACTOR].tsprpal 30
1152
      ifvare temp2 SOBBOTFLY settspr[THISACTOR].tsprpal 30
1149
      ifvare nw_temp2 SOBBOTFLY settspr[THISACTOR].tsprpal 30
1153
      ifvare temp2 APLAYER ifvare skin SANTA settspr[THISACTOR].tsprpal 30
1150
      ifvare nw_temp2 APLAYER ifvare skin SANTA settspr[THISACTOR].tsprpal 30
1154
      break
1151
      break
1155
  endswitch
1152
  endswitch
1156
 
1153
 
1157
 ifvare picnum APLAYER // this fixes the bug with the misplaced TV screen tiles
1154
 ifvare nw_picnum APLAYER // this fixes the bug with the misplaced TV screen tiles
1158
   {
1155
   {
1159
     gettspr[THISACTOR].tsprpicnum temp
1156
     gettspr[THISACTOR].tsprpicnum nw_temp
1160
     switch temp
1157
     switch nw_temp
1161
      case 1470 case 1471 case 1472 case 1473 case 1474
1158
      case 1470 case 1471 case 1472 case 1473 case 1474
1162
       subvar temp 5
1159
       subvar nw_temp 5
1163
       settspr[THISACTOR].tsprpicnum temp
1160
       settspr[THISACTOR].tsprpicnum nw_temp
1164
      break
1161
      break
1165
     endswitch
1162
     endswitch
1166
   }
1163
   }
1167
endevent
1164
endevent
1168
 
1165
 
Line 1174... Line 1171...
1174
  // sizeat 1 1
1171
  // sizeat 1 1
1175
 
1172
 
1176
  ifspritepal 31 // phone ringing effect
1173
  ifspritepal 31 // phone ringing effect
1177
  {
1174
  {
1178
    /*
1175
    /*
1179
    getplayer[THISACTOR].cursectnum temp3
1176
    getplayer[THISACTOR].cursectnum nw_temp3
1180
    switch temp3
1177
    switch nw_temp3
1181
      case 60 case 61 case 62 case 63
1178
      case 60 case 61 case 62 case 63
1182
      case 86 case 87
1179
      case 86 case 87
1183
      case 299 case 300 case 301 case 302 case 303 case 304 case 305 case 306 case 307 case 308 case 309
1180
      case 299 case 300 case 301 case 302 case 303 case 304 case 305 case 306 case 307 case 308 case 309
1184
      case 310 case 311 case 312 case 313 case 314 case 315 case 316 case 317
1181
      case 310 case 311 case 312 case 313 case 314 case 315 case 316 case 317
1185
        soundonce PHONE_RING
1182
        soundonce PHONE_RING
Line 1197... Line 1194...
1197
      stopsound PHONE_RING
1194
      stopsound PHONE_RING
1198
 
1195
 
1199
    ifpdistl RETRIEVEDISTANCE
1196
    ifpdistl RETRIEVEDISTANCE
1200
      ifp pfacing
1197
      ifp pfacing
1201
        ifhitspace
1198
        ifhitspace
1202
          ifvare temp2 0
1199
          ifvare nw_temp2 0
1203
          {
1200
          {
1204
            setvar temp 0
1201
            setvar nw_temp 0
1205
            setvar temp2 1
1202
            setvar nw_temp2 1
1206
            setvar temp3 0
1203
            setvar nw_temp3 0
1207
            setvar tempb 0
1204
            setvar nw_tempb 0
1208
          }
1205
          }
1209
 
1206
 
1210
    ifvare temp2 1
1207
    ifvare nw_temp2 1
1211
    {
1208
    {
1212
      addvar temp 1
1209
      addvar nw_temp 1
1213
 
1210
 
1214
      stopsound PHONE_RING
1211
      stopsound PHONE_RING
1215
      ifvare temp 1
1212
      ifvare nw_temp 1
1216
        sound PHONE_PICKUP
1213
        sound PHONE_PICKUP
1217
      else ifvare temp 30
1214
      else ifvare nw_temp 30
1218
      {
1215
      {
1219
        setvar tempb 0
1216
        setvar nw_tempb 0
1220
        randvar tempb 3
1217
        randvar nw_tempb 3
1221
 
1218
 
1222
        switch tempb
1219
        switch nw_tempb
1223
          case 0
1220
          case 0
1224
            sound LOWANG1
1221
            sound LOWANG1
1225
            setvar temp3 57
1222
            setvar nw_temp3 57
1226
            break
1223
            break
1227
          case 1
1224
          case 1
1228
            sound LOWANG2
1225
            sound LOWANG2
1229
            setvar temp3 124
1226
            setvar nw_temp3 124
1230
            break
1227
            break
1231
          case 2
1228
          case 2
1232
            sound LOWANG3
1229
            sound LOWANG3
1233
            setvar temp3 121
1230
            setvar nw_temp3 121
1234
            break
1231
            break
1235
          case 3
1232
          case 3
1236
            sound LOWANG4
1233
            sound LOWANG4
1237
            setvar temp3 156
1234
            setvar nw_temp3 156
1238
            break
1235
            break
1239
        endswitch
1236
        endswitch
1240
 
1237
 
1241
        addvar temp3 60
1238
        addvar nw_temp3 60
1242
        setvar tempb 0
1239
        setvar nw_tempb 0
1243
      }
1240
      }
1244
      else ifvarvare temp temp3
1241
      else ifvarvare nw_temp nw_temp3
1245
      {
1242
      {
1246
        sound PHONE_HANGUP
1243
        sound PHONE_HANGUP
1247
        setvarvar tempb temp3
1244
        setvarvar nw_tempb nw_temp3
1248
        addvar tempb 150
1245
        addvar nw_tempb 150
1249
      }
1246
      }
1250
      else ifvarvare temp tempb
1247
      else ifvarvare nw_temp nw_tempb
1251
      {
1248
      {
1252
        setvar temp2 0
1249
        setvar nw_temp2 0
1253
        setvar temp 0
1250
        setvar nw_temp 0
1254
      }
1251
      }
1255
    }
1252
    }
1256
  }
1253
  }
1257
enda
1254
enda
1258
 
1255
 
1259
useractor notenemy 3831 0
1256
useractor notenemy 3831 0
1260
// cstat 32768
1257
// cstat 32768
1261
 sizeat 12 13
1258
 sizeat 12 13
1262
 getactor[THISACTOR].sectnum temp
1259
 getactor[THISACTOR].sectnum nw_temp
1263
 getplayer[THISACTOR].cursectnum temp2
1260
 getplayer[THISACTOR].cursectnum nw_temp2
1264
 ifvarvare temp temp2
1261
 ifvarvare nw_temp nw_temp2
1265
   {
1262
   {
1266
     setuserdef[THISACTOR].volume_number 1
1263
     setuserdef[THISACTOR].volume_number 1
1267
     endofgame 13
1264
     endofgame 13
1268
   }
1265
   }
1269
enda
1266
enda
Line 1294... Line 1291...
1294
define title_x2 306
1291
define title_x2 306
1295
define title_y 194
1292
define title_y 194
1296
define title_zoom 32768
1293
define title_zoom 32768
1297
 
1294
 
1298
onevent EVENT_DISPLAYMENU
1295
onevent EVENT_DISPLAYMENU
1299
//  getplayer[THISACTOR].gm temp
1296
//  getplayer[THISACTOR].gm nw_temp
1300
//  ifvarand temp 4 nullop else
1297
//  ifvarand nw_temp 4 nullop else
1301
// {
1298
// {
1302
  rotatesprite title_x1 title_y title_zoom 0 3838 0 0 0 0 0 xdim ydim
1299
  rotatesprite title_x1 title_y title_zoom 0 3838 0 0 0 0 0 xdim ydim
1303
  rotatesprite title_x2 title_y title_zoom 0 3839 0 0 0 0 0 xdim ydim
1300
  rotatesprite title_x2 title_y title_zoom 0 3839 0 0 0 0 0 xdim ydim
1304
// }
1301
// }
1305
endevent
1302
endevent