IMG

 
IMG
IMG   IMG
  Welcome to GTAForums! Be sure to check out the Grand Theft Auto V Forum.

You are not registered! (If you are, click here to login) Registering is fast, free and easy and allows you to instantly reply to any topic on GTAForums.
Why wait? Click here to register your own unique username and become part of the ever-growing community!


( Log In | Register | Revalidate Validation E-mail )
Quick Log-In:
  IMG
       
>
Forum Rules GTA Modification Forums

Please post mod releases in the Mod Showroom

GTAGarage.com
free mod hosting from GTANet, simply login with your GTAForums account details

GTAModding.com
GTANet's modding wiki

GTA Modding Chatroom
provided by irc.gtanet.com (Don't have an IRC client? Click here)


  Reply to this topicStart new topicStart Poll

 Help with changing

 
Your_Girlfriend  
Posted: Thursday, Aug 16 2012, 20:48
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



OK. So... I have an portal mod you all heard about and maybe you have it on your PC. So do I...
Well lets get to the problem: I have found an downloaded a portal gun mod. No it's not a CLEO it's a real portal gun from Portal game. The problem is that portal gun and portal CLEO don't really match. Portal gun replaces shotgspa but portal CLEO spawns tec9. I've been doing some modifications to the CLEO so it can use shotgspa but that didn't went really well. It spawns it but it doesn't shoot portals. I would be happy if someone looks trough the code and finds a problem and a solution.

MINE
CODE


// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007

{$VERSION 3.1.0027}
{$CLEO .cs}

//-------------MAIN---------------
thread 'PORTAL'

:PORTAL_11
wait 0
30@ = -229907
008B: 30@ = &0(30@,1i) // (int)
0085: 31@ = 30@ // (int)
31@ /= 65536
31@ *= 65536
0062: 30@ -= 31@ // (int)
if
 30@ == 20559
else_jump @PORTAL_11
30@ = -229908
if
 &0(30@,1i) == 1381253452
else_jump @PORTAL_11
&0(30@,1i) = 1381253376
03E5: show_text_box 'CHEAT1'  // Cheat activated
9@ = 0
Model.Load(#SHOTGSPA)
038B: load_requested_models

:PORTAL_166
wait 0
if
  Model.Available(#SHOTGSPA)
else_jump @PORTAL_166
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
01B2: give_actor $PLAYER_ACTOR weapon 27 ammo 999999 // Load the weapon model before using this
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 27
0652: 26@ = integer_stat 75
0629: change_integer_stat 75 to 0
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 1, 1, 0)

:PORTAL_247
32@ = 0
wait 0
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_334
if
02D8:   actor $PLAYER_ACTOR current_weapon == 32
else_jump @PORTAL_320
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
jump @PORTAL_334

:PORTAL_320
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1

:PORTAL_334
if and
02D8:   actor $PLAYER_ACTOR current_weapon == 32
 33@ > 500
00E1:   player 0 pressed_key 6
else_jump @PORTAL_373
gosub @PORTAL_951

:PORTAL_373
if and
  Actor.Driving($PLAYER_ACTOR)
 33@ > 500
else_jump @PORTAL_411
0563: set_player $PLAYER_CHAR driveby_ammo_to 0
gosub @PORTAL_951

:PORTAL_411
if
  not 9@ == 0
else_jump @PORTAL_436
gosub @PORTAL_1922

:PORTAL_436
31@ = 1
if and
  Object.Exists(10@)
  Object.Exists(11@)
else_jump @PORTAL_471
gosub @PORTAL_4966

:PORTAL_471
32@ = 0
wait 0
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_558
if
02D8:   actor $PLAYER_ACTOR current_weapon == 32
else_jump @PORTAL_544
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
jump @PORTAL_558

:PORTAL_544
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1

:PORTAL_558
if and
02D8:   actor $PLAYER_ACTOR current_weapon == 32
 33@ > 500
00E1:   player 0 pressed_key 6
else_jump @PORTAL_597
gosub @PORTAL_951

:PORTAL_597
if and
  Actor.Driving($PLAYER_ACTOR)
 33@ > 500
else_jump @PORTAL_635
0563: set_player $PLAYER_CHAR driveby_ammo_to 0
gosub @PORTAL_951

:PORTAL_635
if
  not 9@ == 0
else_jump @PORTAL_660
gosub @PORTAL_1922

:PORTAL_660
31@ = 2
if and
  Object.Exists(10@)
  Object.Exists(11@)
else_jump @PORTAL_695
gosub @PORTAL_4966

:PORTAL_695
30@ = -229907
008B: 30@ = &0(30@,1i) // (int)
0085: 31@ = 30@ // (int)
31@ /= 65536
31@ *= 65536
0062: 30@ -= 31@ // (int)
if
 30@ == 20559
else_jump @PORTAL_247
30@ = -229908
if
 &0(30@,1i) == 1381253452
else_jump @PORTAL_247
&0(30@,1i) = 1381253376
03E5: show_text_box 'CHEAT8'  // Cheat deactivated
if
  Object.Exists(10@)
else_jump @PORTAL_863
Object.Destroy(10@)
Object.Destroy(12@)
06D6: disable_racing_checkpoint 14@

:PORTAL_863
if
  Object.Exists(11@)
else_jump @PORTAL_894
Object.Destroy(11@)
Object.Destroy(13@)
06D6: disable_racing_checkpoint 15@

:PORTAL_894
Model.Destroy(#SHOTGSPA)
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1
0555: remove_weapon 32 from_actor $PLAYER_ACTOR
0629: change_integer_stat 75 to 26@
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 0, 0, 0)
jump @PORTAL_11
end_thread

:PORTAL_951
0A96: 30@ = actor $PLAYER_ACTOR struct
30@ += 1148
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
if
  not 30@ == 0
else_jump @PORTAL_1016
30@ += 44
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1016
if
  not 30@ == 0
else_jump @PORTAL_1053
30@ += 8
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1053
if
  not 30@ == 0
else_jump @PORTAL_1139
if
00E1:   player 0 pressed_key 17
else_jump @PORTAL_1102
9@ = 1
gosub @PORTAL_1252

:PORTAL_1102
if or
00E1:   player 0 pressed_key 4
00E1:   player 0 pressed_key 19
else_jump @PORTAL_1139
9@ = 2
gosub @PORTAL_1252

:PORTAL_1139
if and
  Actor.Driving($PLAYER_ACTOR)
84C8:   not actor $PLAYER_ACTOR driving_flying_vehicle
else_jump @PORTAL_1250
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
047A:   actor $PLAYER_ACTOR driving_bike
else_jump @PORTAL_1250
if
00E1:   player 0 pressed_key 17
else_jump @PORTAL_1219
9@ = 1
gosub @PORTAL_1252

:PORTAL_1219
if
00E1:   player 0 pressed_key 4
else_jump @PORTAL_1250
9@ = 2
gosub @PORTAL_1252

:PORTAL_1250
return

:PORTAL_1252
if
  Actor.Driving($PLAYER_ACTOR)
else_jump @PORTAL_1536
04C4: store_coords_to 6@ 7@ 8@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0
if and
80E1:   not player 0 pressed_key 5
80E1:   not player 0 pressed_key 7
else_jump @PORTAL_1349
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 0.0 1.0 0.0

:PORTAL_1349
if and
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_1401
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 0.0 1.0 0.0

:PORTAL_1401
if and
00E1:   player 0 pressed_key 5
80E1:   not player 0 pressed_key 7
else_jump @PORTAL_1453
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 1.0 0.0 0.0

:PORTAL_1453
if and
80E1:   not player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_1505
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset -1.0 0.0 0.0

:PORTAL_1505
0063: 0@ -= 6@ // (float)
0063: 1@ -= 7@ // (float)
0063: 2@ -= 8@ // (float)
jump @PORTAL_1913

:PORTAL_1536
068D: get_camera_position_to 3@ 4@ 5@
0A96: 30@ = actor $PLAYER_ACTOR struct
30@ += 1148
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
30@ += 44
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
if
  not 30@ == 0
else_jump @PORTAL_1706
30@ += 8
if
  not 30@ == 0
else_jump @PORTAL_1706
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
30@ += 48
0A8D: 0@ = read_memory 30@ size 4 virtual_protect 0
30@ += 4
0A8D: 1@ = read_memory 30@ size 4 virtual_protect 0
30@ += 4
0A8D: 2@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1706
0063: 0@ -= 3@ // (float)
0063: 1@ -= 4@ // (float)
0063: 2@ -= 5@ // (float)
050A: 30@ = distance_between_XYZ 0@ 1@ 2@ and_XYZ 0.0 0.0 0.0
0073: 0@ /= 30@ // (float)
0073: 1@ /= 30@ // (float)
0073: 2@ /= 30@ // (float)
068D: get_camera_position_to 6@ 7@ 8@
Actor.StorePos($PLAYER_ACTOR, 3@, 4@, 5@)
050A: 30@ = distance_between_XYZ 6@ 7@ 8@ and_XYZ 3@ 4@ 5@
30@ += 0.5
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 6@ += 3@ // (float)
005B: 7@ += 4@ // (float)
005B: 8@ += 5@ // (float)

:PORTAL_1913
33@ = 0
return

:PORTAL_1922
0093: 30@ = integer 32@ to_float
30@ *= 0.25
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2620
31@ = 0

:PORTAL_2060
002D:   32@ >= 31@ // (int)
else_jump @PORTAL_2611
0093: 30@ = integer 31@ to_float
30@ *= 0.25
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2597
31@ += -1
0093: 30@ = integer 31@ to_float
30@ *= 0.25
0087: 31@ = 30@ // (float)
31@ += 0.25
9@ *= -1
9@ += 3

:PORTAL_2263
0035:   31@ >= 30@ // (float)
else_jump @PORTAL_2588
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2571
if
  Object.Exists(9@(9@,1i))
else_jump @PORTAL_2466
if
04E6:   object 9@(9@,1i) near_point 6@ 7@ 8@ radius 2.0 2.0 2.0 flag 0
else_jump @PORTAL_2466
9@ = 0
return

:PORTAL_2466
9@ *= -1
9@ += 3
30@ += -0.0001
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 6@ += 3@ // (float)
005B: 7@ += 4@ // (float)
005B: 8@ += 5@ // (float)
gosub @PORTAL_2738
return

:PORTAL_2571
30@ += 0.0001
jump @PORTAL_2263

:PORTAL_2588
9@ = 0
return

:PORTAL_2597
31@ += 1
jump @PORTAL_2060

:PORTAL_2611
9@ = 0
return

:PORTAL_2620
if
 9@ == 1
else_jump @PORTAL_2666
04D5: create_corona_at 3@ 4@ 5@ radius 0.2 type 0 flare 0 RGB 0 128 255

:PORTAL_2666
if
 9@ == 2
else_jump @PORTAL_2712
04D5: create_corona_at 3@ 4@ 5@ radius 0.2 type 0 flare 0 RGB 255 128 0

:PORTAL_2712
0087: 6@ = 3@ // (float)
0087: 7@ = 4@ // (float)
0087: 8@ = 5@ // (float)
return

:PORTAL_2738
0087: 4@ = 0@ // (float)
0087: 5@ = 1@ // (float)
gosub @PORTAL_11167
3@ *= -1.0
0087: 17@ = 3@ // (float)
0087: 18@ = 3@ // (float)
0087: 31@ = 3@ // (float)
0087: 4@ = 2@ // (float)
0509: 5@ = distance_between_XY 0@ 1@ and_XY 0.0 0.0
gosub @PORTAL_11167
3@ *= -1.0
0087: 16@ = 3@ // (float)
18@ += -182.5
31@ += 182.5
02F6: 0@ = sine 18@ // (float)
0@ *= 0.025
02F7: 1@ = cosine 18@ // (float)
1@ *= 0.025
2@ = 0.0
005B: 0@ += 6@ // (float)
005B: 1@ += 7@ // (float)
005B: 2@ += 8@ // (float)

:PORTAL_2939
0025:   31@ > 18@ // (float)
else_jump @PORTAL_3298
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
5@ = 0.0
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3257
0087: 31@ = 18@ // (float)
18@ += -1.0

:PORTAL_3083
0025:   31@ > 18@ // (float)
else_jump @PORTAL_3257
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
5@ = 0.0
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3216
jump @PORTAL_3257

:PORTAL_3216
18@ += 0.1
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3083

:PORTAL_3257
18@ += 1.0
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_2939

:PORTAL_3298
18@ += 90.0
16@ *= -1.0
0087: 31@ = 16@ // (float)
16@ += -92.5
31@ += 272.5
02F6: 0@ = sine 18@ // (float)
0@ *= 0.025
02F7: 1@ = cosine 18@ // (float)
1@ *= 0.025
02F6: 2@ = sine 16@ // (float)
006B: 0@ *= 2@ // (float)
006B: 1@ *= 2@ // (float)
02F7: 2@ = cosine 16@ // (float)
2@ *= 0.025
005B: 0@ += 6@ // (float)
005B: 1@ += 7@ // (float)
005B: 2@ += 8@ // (float)

:PORTAL_3448
0025:   31@ > 16@ // (float)
else_jump @PORTAL_3871
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
02F6: 5@ = sine 16@ // (float)
006B: 3@ *= 5@ // (float)
006B: 4@ *= 5@ // (float)
02F7: 5@ = cosine 16@ // (float)
5@ *= 0.025
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3830
0087: 31@ = 16@ // (float)
16@ += -1.0

:PORTAL_3624
0025:   31@ > 16@ // (float)
else_jump @PORTAL_3830
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
02F6: 5@ = sine 16@ // (float)
006B: 3@ *= 5@ // (float)
006B: 4@ *= 5@ // (float)
02F7: 5@ = cosine 16@ // (float)
5@ *= 0.025
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3789
jump @PORTAL_3830

:PORTAL_3789
16@ += 0.1
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3624

:PORTAL_3830
16@ += 1.0
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3448

:PORTAL_3871
18@ *= -1.0
16@ *= -1.0
16@ += -270.0
02F7: 30@ = cosine 16@ // (float)
if
 0.0 > 30@
else_jump @PORTAL_3950
16@ *= -1.0
18@ += -180.0

:PORTAL_3950
if and
 16@ >= -362.5
 -357.5 >= 16@
else_jump @PORTAL_4009
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4009
if and
 16@ >= -182.5
 -172.5 >= 16@
else_jump @PORTAL_4078
16@ = 180.0
0087: 18@ = 17@ // (float)
18@ *= -1.0
18@ += 180.0

:PORTAL_4078
if and
 16@ >= -2.5
 2.5 >= 16@
else_jump @PORTAL_4137
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4137
if and
 16@ >= 172.5
 182.5 >= 16@
else_jump @PORTAL_4206
16@ = 180.0
0087: 18@ = 17@ // (float)
18@ *= -1.0
18@ += 180.0

:PORTAL_4206
if and
 16@ >= 357.5
 362.5 >= 16@
else_jump @PORTAL_4265
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4265
if
  Object.Exists(9@(9@,1i))
else_jump @PORTAL_4312
Object.Destroy(9@(9@,1i))
Object.Destroy(11@(9@,1i))
06D6: disable_racing_checkpoint 13@(9@,1i)

:PORTAL_4312
16@ += 90.0
17@ += 180.0
9@(9@,1i) = Object.Create(#SHOTGSPA, 6@, 7@, 8@)
11@(9@,1i) = Object.Create(#SHOTGSPA, 0.0, 0.0, 0.0)
0453: set_object 9@(9@,1i) XY_rotation 16@ 180.0 angle 18@
0453: set_object 11@(9@,1i) XY_rotation 16@ 18@ angle 180.0
0750: set_object 9@(9@,1i) visibility 0
0750: set_object 11@(9@,1i) visibility 0
Object.CollisionDetection(9@(9@,1i)) = False
Object.CollisionDetection(11@(9@,1i)) = False
Object.SetImmunities(9@(9@,1i), 1, 1, 1, 1, 1)
Object.SetImmunities(11@(9@,1i), 1, 1, 1, 1, 1)
Object.KeepInMemory(9@(9@,1i)) = True
Object.KeepInMemory(11@(9@,1i)) = True
0400: store_coords_to 0@ 1@ 2@ from_object 9@(9@,1i) with_offset 0.0 100.0 0.0
06D5: 13@(9@,1i) = create_racing_checkpoint_at 6@ 7@ 8@ point_to 0@ 1@ 2@ type 3 radius 1.0
0A8D: 0@ = read_memory 13103464 size 4 virtual_protect 0
0A8D: 1@ = read_memory 13103468 size 4 virtual_protect 0
0A8D: 2@ = read_memory 13103472 size 4 virtual_protect 0
if and
0045:   0@ == 6@ // (float)
0045:   1@ == 7@ // (float)
0045:   2@ == 8@ // (float)
else_jump @PORTAL_4736
if
 9@ == 1
else_jump @PORTAL_4702
0A8C: write_memory 13103456 size 4 value -1056997376 virtual_protect 0

:PORTAL_4702
if
 9@ == 2
else_jump @PORTAL_4736
0A8C: write_memory 13103456 size 4 value -1073708801 virtual_protect 0

:PORTAL_4736
0A8D: 0@ = read_memory 13103520 size 4 virtual_protect 0
0A8D: 1@ = read_memory 13103524 size 4 virtual_protect 0
0A8D: 2@ = read_memory 13103528 size 4 virtual_protect 0
if and
0045:   0@ == 6@ // (float)
0045:   1@ == 7@ // (float)
0045:   2@ == 8@ // (float)
else_jump @PORTAL_4881
if
 9@ == 1
else_jump @PORTAL_4847
0A8C: write_memory 13103512 size 4 value -1056997376 virtual_protect 0

:PORTAL_4847
if
 9@ == 2
else_jump @PORTAL_4881
0A8C: write_memory 13103512 size 4 value -1073708801 virtual_protect 0

:PORTAL_4881
if
 9@ == 1
else_jump @PORTAL_4919
018C: play_sound 1052 at 0.0 0.0 0.0

:PORTAL_4919
if
 9@ == 2
else_jump @PORTAL_4957
018C: play_sound 1054 at 0.0 0.0 0.0

:PORTAL_4957
9@ = 0
return

:PORTAL_4966
30@ = 1
27@ = 0

:PORTAL_4980
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_4995
if
  Actor.Defined(25@)
else_jump @PORTAL_5041
if
  not Actor.Driving(25@)
else_jump @PORTAL_5041
gosub @PORTAL_5350
jump @PORTAL_5069

:PORTAL_5041
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_4995

:PORTAL_5069
27@ += 256
 27@ > 35584
else_jump @PORTAL_4980
30@ = 2
27@ = 0

:PORTAL_5108
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_5123
if
  Car.Defined(25@)
else_jump @PORTAL_5153
gosub @PORTAL_5350
jump @PORTAL_5181

:PORTAL_5153
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_5123

:PORTAL_5181
27@ += 256
 27@ > 27904
else_jump @PORTAL_5108
30@ = 3
27@ = 0

:PORTAL_5218
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_5233
if and
  Object.Exists(25@)
803B:   not  10@ == 25@ // (int)
803B:   not  11@ == 25@ // (int)
803B:   not  12@ == 25@ // (int)
803B:   not  13@ == 25@ // (int)
else_jump @PORTAL_5295
gosub @PORTAL_5350
jump @PORTAL_5323

:PORTAL_5295
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_5233

:PORTAL_5323
27@ += 256
 27@ > 89344
else_jump @PORTAL_5218
return

:PORTAL_5350
if
 30@ == 1
else_jump @PORTAL_5397
04C4: store_coords_to 19@ 20@ 21@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_5397
if
 30@ == 2
else_jump @PORTAL_5444
0407: store_coords_to 19@ 20@ 21@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_5444
if
 30@ == 3
else_jump @PORTAL_5491
0400: store_coords_to 19@ 20@ 21@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_5491
Object.StorePos(9@(31@,1i), 19@, 20@, 21@)
if
04E6:   object 9@(31@,1i) near_point 19@ 20@ 21@ radius 10.0 10.0 10.0 flag 0
0AA1: return_if_false
if
 30@ == 1
else_jump @PORTAL_5582
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@

:PORTAL_5582
if
 30@ == 2
else_jump @PORTAL_5614
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@

:PORTAL_5614
if
 30@ == 3
else_jump @PORTAL_5646
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@

:PORTAL_5646
18@ += -1.0
0400: store_coords_to 16@ 18@ 17@ from_object 11@(31@,1i) with_offset 16@ 18@ 17@
if
 0.0 > 17@
0AA1: return_if_false
if
 30@ == 1
else_jump @PORTAL_5753
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5753
if
 30@ == 2
else_jump @PORTAL_5807
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5807
if
 30@ == 3
else_jump @PORTAL_5861
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5861
0509: 17@ = distance_between_XY 16@ 18@ and_XY 0.0 0.0
if
  not 30@ == 2
else_jump @PORTAL_5923
if
 2.0 > 17@
0AA1: return_if_false
jump @PORTAL_5939

:PORTAL_5923
if
 1.0 > 17@
0AA1: return_if_false

:PORTAL_5939
if
 30@ == 1
else_jump @PORTAL_6588
0665: get_actor 25@ model_to 5@
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 20@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 20@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 23@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 23@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 20@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 20@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 23@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 23@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_6588
if
 30@ == 2
else_jump @PORTAL_7237
5@ = Car.Model(25@)
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 20@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 20@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 23@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 23@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 20@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 20@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 23@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 23@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_7237
if
 30@ == 3
else_jump @PORTAL_7886
5@ = Object.Model(25@)
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 20@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 20@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 23@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 23@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 20@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 20@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 23@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 23@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_7886
return

:PORTAL_7888
if
 30@ == 2
else_jump @PORTAL_7920
04FE: deflate_tire 5 on_car 25@
0699: set_car 25@ repair_tire 5

:PORTAL_7920
gosub @PORTAL_8081
return

:PORTAL_7929
0093: 29@ = integer 32@ to_float
29@ *= 0.0035
006B: 16@ *= 29@ // (float)
006B: 17@ *= 29@ // (float)
006B: 18@ *= 29@ // (float)
005B: 3@ += 16@ // (float)
005B: 4@ += 17@ // (float)
005B: 5@ += 18@ // (float)

:PORTAL_7995
0400: store_coords_to 16@ 17@ 18@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 16@ -= 3@ // (float)
0063: 17@ -= 4@ // (float)
0063: 18@ -= 5@ // (float)
0400: store_coords_to 16@ 18@ 17@ from_object 11@(31@,1i) with_offset 16@ 18@ 17@
return

:PORTAL_8081
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8161
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_8161
if
 30@ == 2
else_jump @PORTAL_8208
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_8208
if
 30@ == 3
else_jump @PORTAL_8255
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_8255
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
0@ *= -1.0
1@ *= -1.0
2@ *= -1.0
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8416
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 1.0 0.0

:PORTAL_8416
if
 30@ == 2
else_jump @PORTAL_8463
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 1.0 0.0

:PORTAL_8463
if
 30@ == 3
else_jump @PORTAL_8510
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 1.0 0.0

:PORTAL_8510
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= 1.0
21@ *= -1.0
0063: 19@ -= 0@ // (float)
0063: 20@ -= 1@ // (float)
0063: 21@ -= 2@ // (float)
0087: 4@ = 19@ // (float)
0087: 5@ = 20@ // (float)
gosub @PORTAL_11167
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8718
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 0.0 1.0

:PORTAL_8718
if
 30@ == 2
else_jump @PORTAL_8765
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 0.0 1.0

:PORTAL_8765
if
 30@ == 3
else_jump @PORTAL_8812
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 0.0 1.0

:PORTAL_8812
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= -1.0
21@ *= -1.0
0063: 19@ -= 0@ // (float)
0063: 20@ -= 1@ // (float)
0063: 21@ -= 2@ // (float)
0087: 18@ = 3@ // (float)
18@ += -90.0
0087: 16@ = 19@ // (float)
0087: 17@ = 20@ // (float)
02F6: 4@ = sine 18@ // (float)
02F7: 5@ = cosine 18@ // (float)
006B: 16@ *= 5@ // (float)
006B: 17@ *= 5@ // (float)
006B: 19@ *= 4@ // (float)
006B: 20@ *= 4@ // (float)
17@ *= -1.0
005B: 19@ += 17@ // (float)
005B: 20@ += 16@ // (float)
0087: 18@ = 3@ // (float)
0087: 4@ = 20@ // (float)
0087: 5@ = 21@ // (float)
gosub @PORTAL_11167
0087: 16@ = 3@ // (float)
16@ *= -1.0
16@ += 360.0
0087: 4@ = 19@ // (float)
0509: 5@ = distance_between_XY 20@ 21@ and_XY 0.0 0.0
gosub @PORTAL_11167
0087: 17@ = 3@ // (float)
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_9208
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_9208
if
 30@ == 2
else_jump @PORTAL_9255
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_9255
if
 30@ == 3
else_jump @PORTAL_9302
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_9302
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
0400: store_coords_to 3@ 5@ 4@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
3@ *= -1.0
4@ *= -1.0
5@ *= -1.0
18@ += 180.0
if
 30@ == 1
else_jump @PORTAL_9497
18@ = Actor.Angle(25@)
16@ = Object.Angle(9@(31@,1i))
31@ *= -1
31@ += 3
17@ = Object.Angle(9@(31@,1i))
31@ *= -1
31@ += 3
0063: 18@ -= 16@ // (float)
005B: 18@ += 17@ // (float)
18@ += 180.0

:PORTAL_9497
if
 30@ == 1
else_jump @PORTAL_9556
083D: get_actor 25@ velocity_in_direction_XYZ 19@ 20@ 21@
0619: enable_actor 25@ collision_detection 0
083C: set_actor 25@ velocity_in_direction_XYZ 0.0 0.0 0.0

:PORTAL_9556
if
 30@ == 2
else_jump @PORTAL_9650
06A2: get_car 25@ velocity_in_direction_XYZ 19@ 20@ 21@
099A: set_car 25@ collision_detection 0
07D5: set_car 25@ velocity_in_direction_XYZ 0.0 0.0 0.0 rotation_velocitiesXY 0.0 0.0 unk 0.0
07DB: set_car 25@ rotation_velocity_XYZ 0.0 0.0 0.0 through_center_of_mass

:PORTAL_9650
if
 30@ == 3
else_jump @PORTAL_9729
059F: get_object 25@ velocity_in_direction 19@ 20@ 21@
Object.CollisionDetection(25@) = False
Object.Throw(25@, 0.0, 0.0, 0.0)
05A2: set_object 25@ rotation_velocity_about_an_axis 0.0 0.0 0.0 through_center_of_mass

:PORTAL_9729
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= -1.0
20@ += 2.5
31@ *= -1
31@ += 3
if
 30@ == 1
else_jump @PORTAL_10370
if
003C:   $PLAYER_ACTOR == 25@ // (int)
else_jump @PORTAL_10018
31@ *= -1
31@ += 3
0400: store_coords_to 6@ 7@ 8@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
068D: get_camera_position_to 0@ 1@ 2@
0063: 6@ -= 0@ // (float)
0063: 7@ -= 1@ // (float)
0063: 8@ -= 2@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 6@ 8@ 7@
2@ *= -1.0
31@ *= -1
31@ += 3
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)

:PORTAL_10018
0470: 24@ = actor 25@ current_weapon
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 3@ 4@ 5@
0A96: 0@ = actor 25@ struct
0@ += 20
0A8D: 0@ = read_memory 0@ size 4 virtual_protect 0
0@ += 48
0A8C: write_memory 0@ size 4 value 3@ virtual_protect 0
0@ += 4
0A8C: write_memory 0@ size 4 value 4@ virtual_protect 0
0@ += 4
0A8C: write_memory 0@ size 4 value 5@ virtual_protect 0
Actor.Angle(25@) = 18@
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
0619: enable_actor 25@ collision_detection 1
083C: set_actor 25@ velocity_in_direction_XYZ 19@ 20@ 21@
if
003C:   $PLAYER_ACTOR == 25@ // (int)
else_jump @PORTAL_10370
0400: store_coords_to 0@ 1@ 2@ from_object 9@(31@,1i) with_offset 0@ 1@ 2@
Camera.SetPosition(0@, 1@, 2@, 0.0, 0.0, 0.0)
04C4: store_coords_to 0@ 1@ 2@ from_actor 25@ with_offset 0.0 0.0 0.5
Camera.PointAt(0@, 1@, 2@, 2)
wait 0
Camera.Restore

:PORTAL_10370
if
 30@ == 2
else_jump @PORTAL_10926
if
  Actor.InCar($PLAYER_ACTOR, 25@)
else_jump @PORTAL_10584
31@ *= -1
31@ += 3
0407: store_coords_to 6@ 7@ 8@ from_car 25@ with_offset 0.0 0.0 0.0
068D: get_camera_position_to 0@ 1@ 2@
0063: 6@ -= 0@ // (float)
0063: 7@ -= 1@ // (float)
0063: 8@ -= 2@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 6@ 8@ 7@
2@ *= -1.0
31@ *= -1
31@ += 3
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)

:PORTAL_10584
0939: attach_car 25@ to_object 9@(31@,1i) with_offset 3@ 4@ 5@ rotation 16@ 17@ 18@
0684: detach_car 25@ 0.0 0.0 0.0 collision_detection 1
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
19@ *= 0.015
20@ *= 0.015
21@ *= 0.015
099A: set_car 25@ collision_detection 1
07D5: set_car 25@ velocity_in_direction_XYZ 19@ 20@ 21@ rotation_velocitiesXY 0.0 0.0 unk 0.0
07DB: set_car 25@ rotation_velocity_XYZ 0.0 0.0 0.0 through_center_of_mass
if
  Actor.InCar($PLAYER_ACTOR, 25@)
else_jump @PORTAL_10926
0400: store_coords_to 0@ 1@ 2@ from_object 9@(31@,1i) with_offset 0@ 1@ 2@
Camera.SetPosition(0@, 1@, 2@, 0.0, 0.0, 0.0)
0407: store_coords_to 0@ 1@ 2@ from_car 25@ with_offset 0.0 0.0 1.0
Camera.PointAt(0@, 1@, 2@, 2)
wait 0
Camera.Restore

:PORTAL_10926
if
 30@ == 3
else_jump @PORTAL_11131
16@ += 180.0
069A: attach_object 25@ to_object 9@(31@,1i) with_offset 3@ 4@ 5@ rotation 16@ 17@ 18@
0682: detach_object 25@ 0.0 0.0 0.0 collision_detection 1
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
Object.CollisionDetection(25@) = True
Object.Throw(25@, 19@, 20@, 21@)
05A2: set_object 25@ rotation_velocity_about_an_axis 0.0 0.0 0.0 through_center_of_mass

:PORTAL_11131
31@ *= -1
31@ += 3
018C: play_sound 1150 at 0.0 0.0 0.0
return

:PORTAL_11167
0509: 3@ = distance_between_XY 4@ 5@ and_XY 0.0 0.0
0073: 4@ /= 3@ // (float)
0073: 5@ /= 3@ // (float)
0509: 3@ = distance_between_XY 4@ 5@ and_XY 0.0 1.0
24@ = 0

:PORTAL_11232
3@ /= 2.0
006B: 3@ *= 3@ // (float)
0087: 5@ = 3@ // (float)
3@ *= -1.0
3@ += 1.0
01FB: 3@ = square_root 3@
3@ *= -1.0
3@ += 1.0
006B: 3@ *= 3@ // (float)
005B: 3@ += 5@ // (float)
01FB: 3@ = square_root 3@
24@ += 1
 24@ > 15
else_jump @PORTAL_11232
3@ *= 65536.0
3@ *= 180.0
3@ /= 3.141593
if
 4@ > 0.0
else_jump @PORTAL_11422
3@ *= -1.0
3@ += 360.0

:PORTAL_11422
return



ORIGINAL
CODE


// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007

{$VERSION 3.1.0027}
{$CLEO .cs}

//-------------MAIN---------------
thread 'PORTAL'

:PORTAL_11
wait 0
30@ = -229907
008B: 30@ = &0(30@,1i) // (int)
0085: 31@ = 30@ // (int)
31@ /= 65536
31@ *= 65536
0062: 30@ -= 31@ // (int)
if
 30@ == 20559
else_jump @PORTAL_11
30@ = -229908
if
 &0(30@,1i) == 1381253452
else_jump @PORTAL_11
&0(30@,1i) = 1381253376
03E5: show_text_box 'CHEAT1'  // Cheat activated
9@ = 0
Model.Load(#TEC9)
038B: load_requested_models

:PORTAL_166
wait 0
if
  Model.Available(#TEC9)
else_jump @PORTAL_166
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
01B2: give_actor $PLAYER_ACTOR weapon 32 ammo 999999 // Load the weapon model before using this
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 32
0652: 26@ = integer_stat 75
0629: change_integer_stat 75 to 0
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 1, 1, 0)

:PORTAL_247
32@ = 0
wait 0
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_334
if
02D8:   actor $PLAYER_ACTOR current_weapon == 32
else_jump @PORTAL_320
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
jump @PORTAL_334

:PORTAL_320
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1

:PORTAL_334
if and
02D8:   actor $PLAYER_ACTOR current_weapon == 32
 33@ > 500
00E1:   player 0 pressed_key 6
else_jump @PORTAL_373
gosub @PORTAL_951

:PORTAL_373
if and
  Actor.Driving($PLAYER_ACTOR)
 33@ > 500
else_jump @PORTAL_411
0563: set_player $PLAYER_CHAR driveby_ammo_to 0
gosub @PORTAL_951

:PORTAL_411
if
  not 9@ == 0
else_jump @PORTAL_436
gosub @PORTAL_1922

:PORTAL_436
31@ = 1
if and
  Object.Exists(10@)
  Object.Exists(11@)
else_jump @PORTAL_471
gosub @PORTAL_4966

:PORTAL_471
32@ = 0
wait 0
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_558
if
02D8:   actor $PLAYER_ACTOR current_weapon == 32
else_jump @PORTAL_544
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 0
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 0
jump @PORTAL_558

:PORTAL_544
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1

:PORTAL_558
if and
02D8:   actor $PLAYER_ACTOR current_weapon == 32
 33@ > 500
00E1:   player 0 pressed_key 6
else_jump @PORTAL_597
gosub @PORTAL_951

:PORTAL_597
if and
  Actor.Driving($PLAYER_ACTOR)
 33@ > 500
else_jump @PORTAL_635
0563: set_player $PLAYER_CHAR driveby_ammo_to 0
gosub @PORTAL_951

:PORTAL_635
if
  not 9@ == 0
else_jump @PORTAL_660
gosub @PORTAL_1922

:PORTAL_660
31@ = 2
if and
  Object.Exists(10@)
  Object.Exists(11@)
else_jump @PORTAL_695
gosub @PORTAL_4966

:PORTAL_695
30@ = -229907
008B: 30@ = &0(30@,1i) // (int)
0085: 31@ = 30@ // (int)
31@ /= 65536
31@ *= 65536
0062: 30@ -= 31@ // (int)
if
 30@ == 20559
else_jump @PORTAL_247
30@ = -229908
if
 &0(30@,1i) == 1381253452
else_jump @PORTAL_247
&0(30@,1i) = 1381253376
03E5: show_text_box 'CHEAT8'  // Cheat deactivated
if
  Object.Exists(10@)
else_jump @PORTAL_863
Object.Destroy(10@)
Object.Destroy(12@)
06D6: disable_racing_checkpoint 14@

:PORTAL_863
if
  Object.Exists(11@)
else_jump @PORTAL_894
Object.Destroy(11@)
Object.Destroy(13@)
06D6: disable_racing_checkpoint 15@

:PORTAL_894
Model.Destroy(#TEC9)
082A: set_player $PLAYER_CHAR able_to_use_crouch_button 1
0881: set_player $PLAYER_CHAR able_to_shoot_weapons 1
0555: remove_weapon 32 from_actor $PLAYER_ACTOR
0629: change_integer_stat 75 to 26@
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 0, 0, 0)
jump @PORTAL_11
end_thread

:PORTAL_951
0A96: 30@ = actor $PLAYER_ACTOR struct
30@ += 1148
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
if
  not 30@ == 0
else_jump @PORTAL_1016
30@ += 44
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1016
if
  not 30@ == 0
else_jump @PORTAL_1053
30@ += 8
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1053
if
  not 30@ == 0
else_jump @PORTAL_1139
if
00E1:   player 0 pressed_key 17
else_jump @PORTAL_1102
9@ = 1
gosub @PORTAL_1252

:PORTAL_1102
if or
00E1:   player 0 pressed_key 4
00E1:   player 0 pressed_key 19
else_jump @PORTAL_1139
9@ = 2
gosub @PORTAL_1252

:PORTAL_1139
if and
  Actor.Driving($PLAYER_ACTOR)
84C8:   not actor $PLAYER_ACTOR driving_flying_vehicle
else_jump @PORTAL_1250
if or
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
047A:   actor $PLAYER_ACTOR driving_bike
else_jump @PORTAL_1250
if
00E1:   player 0 pressed_key 17
else_jump @PORTAL_1219
9@ = 1
gosub @PORTAL_1252

:PORTAL_1219
if
00E1:   player 0 pressed_key 4
else_jump @PORTAL_1250
9@ = 2
gosub @PORTAL_1252

:PORTAL_1250
return

:PORTAL_1252
if
  Actor.Driving($PLAYER_ACTOR)
else_jump @PORTAL_1536
04C4: store_coords_to 6@ 7@ 8@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0
if and
80E1:   not player 0 pressed_key 5
80E1:   not player 0 pressed_key 7
else_jump @PORTAL_1349
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 0.0 1.0 0.0

:PORTAL_1349
if and
00E1:   player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_1401
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 0.0 1.0 0.0

:PORTAL_1401
if and
00E1:   player 0 pressed_key 5
80E1:   not player 0 pressed_key 7
else_jump @PORTAL_1453
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 1.0 0.0 0.0

:PORTAL_1453
if and
80E1:   not player 0 pressed_key 5
00E1:   player 0 pressed_key 7
else_jump @PORTAL_1505
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset -1.0 0.0 0.0

:PORTAL_1505
0063: 0@ -= 6@ // (float)
0063: 1@ -= 7@ // (float)
0063: 2@ -= 8@ // (float)
jump @PORTAL_1913

:PORTAL_1536
068D: get_camera_position_to 3@ 4@ 5@
0A96: 30@ = actor $PLAYER_ACTOR struct
30@ += 1148
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
30@ += 44
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
if
  not 30@ == 0
else_jump @PORTAL_1706
30@ += 8
if
  not 30@ == 0
else_jump @PORTAL_1706
0A8D: 30@ = read_memory 30@ size 4 virtual_protect 0
30@ += 48
0A8D: 0@ = read_memory 30@ size 4 virtual_protect 0
30@ += 4
0A8D: 1@ = read_memory 30@ size 4 virtual_protect 0
30@ += 4
0A8D: 2@ = read_memory 30@ size 4 virtual_protect 0

:PORTAL_1706
0063: 0@ -= 3@ // (float)
0063: 1@ -= 4@ // (float)
0063: 2@ -= 5@ // (float)
050A: 30@ = distance_between_XYZ 0@ 1@ 2@ and_XYZ 0.0 0.0 0.0
0073: 0@ /= 30@ // (float)
0073: 1@ /= 30@ // (float)
0073: 2@ /= 30@ // (float)
068D: get_camera_position_to 6@ 7@ 8@
Actor.StorePos($PLAYER_ACTOR, 3@, 4@, 5@)
050A: 30@ = distance_between_XYZ 6@ 7@ 8@ and_XYZ 3@ 4@ 5@
30@ += 0.5
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 6@ += 3@ // (float)
005B: 7@ += 4@ // (float)
005B: 8@ += 5@ // (float)

:PORTAL_1913
33@ = 0
return

:PORTAL_1922
0093: 30@ = integer 32@ to_float
30@ *= 0.25
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2620
31@ = 0

:PORTAL_2060
002D:   32@ >= 31@ // (int)
else_jump @PORTAL_2611
0093: 30@ = integer 31@ to_float
30@ *= 0.25
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2597
31@ += -1
0093: 30@ = integer 31@ to_float
30@ *= 0.25
0087: 31@ = 30@ // (float)
31@ += 0.25
9@ *= -1
9@ += 3

:PORTAL_2263
0035:   31@ >= 30@ // (float)
else_jump @PORTAL_2588
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 3@ 4@ 5@ and 6@ 7@ 8@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_2571
if
  Object.Exists(9@(9@,1i))
else_jump @PORTAL_2466
if
04E6:   object 9@(9@,1i) near_point 6@ 7@ 8@ radius 2.0 2.0 2.0 flag 0
else_jump @PORTAL_2466
9@ = 0
return

:PORTAL_2466
9@ *= -1
9@ += 3
30@ += -0.0001
0087: 3@ = 0@ // (float)
0087: 4@ = 1@ // (float)
0087: 5@ = 2@ // (float)
006B: 3@ *= 30@ // (float)
006B: 4@ *= 30@ // (float)
006B: 5@ *= 30@ // (float)
005B: 6@ += 3@ // (float)
005B: 7@ += 4@ // (float)
005B: 8@ += 5@ // (float)
gosub @PORTAL_2738
return

:PORTAL_2571
30@ += 0.0001
jump @PORTAL_2263

:PORTAL_2588
9@ = 0
return

:PORTAL_2597
31@ += 1
jump @PORTAL_2060

:PORTAL_2611
9@ = 0
return

:PORTAL_2620
if
 9@ == 1
else_jump @PORTAL_2666
04D5: create_corona_at 3@ 4@ 5@ radius 0.2 type 0 flare 0 RGB 0 128 255

:PORTAL_2666
if
 9@ == 2
else_jump @PORTAL_2712
04D5: create_corona_at 3@ 4@ 5@ radius 0.2 type 0 flare 0 RGB 255 128 0

:PORTAL_2712
0087: 6@ = 3@ // (float)
0087: 7@ = 4@ // (float)
0087: 8@ = 5@ // (float)
return

:PORTAL_2738
0087: 4@ = 0@ // (float)
0087: 5@ = 1@ // (float)
gosub @PORTAL_11167
3@ *= -1.0
0087: 17@ = 3@ // (float)
0087: 18@ = 3@ // (float)
0087: 31@ = 3@ // (float)
0087: 4@ = 2@ // (float)
0509: 5@ = distance_between_XY 0@ 1@ and_XY 0.0 0.0
gosub @PORTAL_11167
3@ *= -1.0
0087: 16@ = 3@ // (float)
18@ += -182.5
31@ += 182.5
02F6: 0@ = sine 18@ // (float)
0@ *= 0.025
02F7: 1@ = cosine 18@ // (float)
1@ *= 0.025
2@ = 0.0
005B: 0@ += 6@ // (float)
005B: 1@ += 7@ // (float)
005B: 2@ += 8@ // (float)

:PORTAL_2939
0025:   31@ > 18@ // (float)
else_jump @PORTAL_3298
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
5@ = 0.0
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3257
0087: 31@ = 18@ // (float)
18@ += -1.0

:PORTAL_3083
0025:   31@ > 18@ // (float)
else_jump @PORTAL_3257
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
5@ = 0.0
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3216
jump @PORTAL_3257

:PORTAL_3216
18@ += 0.1
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3083

:PORTAL_3257
18@ += 1.0
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_2939

:PORTAL_3298
18@ += 90.0
16@ *= -1.0
0087: 31@ = 16@ // (float)
16@ += -92.5
31@ += 272.5
02F6: 0@ = sine 18@ // (float)
0@ *= 0.025
02F7: 1@ = cosine 18@ // (float)
1@ *= 0.025
02F6: 2@ = sine 16@ // (float)
006B: 0@ *= 2@ // (float)
006B: 1@ *= 2@ // (float)
02F7: 2@ = cosine 16@ // (float)
2@ *= 0.025
005B: 0@ += 6@ // (float)
005B: 1@ += 7@ // (float)
005B: 2@ += 8@ // (float)

:PORTAL_3448
0025:   31@ > 16@ // (float)
else_jump @PORTAL_3871
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
02F6: 5@ = sine 16@ // (float)
006B: 3@ *= 5@ // (float)
006B: 4@ *= 5@ // (float)
02F7: 5@ = cosine 16@ // (float)
5@ *= 0.025
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3830
0087: 31@ = 16@ // (float)
16@ += -1.0

:PORTAL_3624
0025:   31@ > 16@ // (float)
else_jump @PORTAL_3830
02F6: 3@ = sine 18@ // (float)
3@ *= 0.025
02F7: 4@ = cosine 18@ // (float)
4@ *= 0.025
02F6: 5@ = sine 16@ // (float)
006B: 3@ *= 5@ // (float)
006B: 4@ *= 5@ // (float)
02F7: 5@ = cosine 16@ // (float)
5@ *= 0.025
005B: 3@ += 6@ // (float)
005B: 4@ += 7@ // (float)
005B: 5@ += 8@ // (float)
if
86BD:   not no_obstacles_between 0@ 1@ 2@ and 3@ 4@ 5@ solid 1 car 0 actor 0 object 0 particle 0
else_jump @PORTAL_3789
jump @PORTAL_3830

:PORTAL_3789
16@ += 0.1
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3624

:PORTAL_3830
16@ += 1.0
0087: 0@ = 3@ // (float)
0087: 1@ = 4@ // (float)
0087: 2@ = 5@ // (float)
jump @PORTAL_3448

:PORTAL_3871
18@ *= -1.0
16@ *= -1.0
16@ += -270.0
02F7: 30@ = cosine 16@ // (float)
if
 0.0 > 30@
else_jump @PORTAL_3950
16@ *= -1.0
18@ += -180.0

:PORTAL_3950
if and
 16@ >= -362.5
 -357.5 >= 16@
else_jump @PORTAL_4009
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4009
if and
 16@ >= -182.5
 -172.5 >= 16@
else_jump @PORTAL_4078
16@ = 180.0
0087: 18@ = 17@ // (float)
18@ *= -1.0
18@ += 180.0

:PORTAL_4078
if and
 16@ >= -2.5
 2.5 >= 16@
else_jump @PORTAL_4137
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4137
if and
 16@ >= 172.5
 182.5 >= 16@
else_jump @PORTAL_4206
16@ = 180.0
0087: 18@ = 17@ // (float)
18@ *= -1.0
18@ += 180.0

:PORTAL_4206
if and
 16@ >= 357.5
 362.5 >= 16@
else_jump @PORTAL_4265
16@ = 0.0
0087: 18@ = 17@ // (float)
18@ *= -1.0

:PORTAL_4265
if
  Object.Exists(9@(9@,1i))
else_jump @PORTAL_4312
Object.Destroy(9@(9@,1i))
Object.Destroy(11@(9@,1i))
06D6: disable_racing_checkpoint 13@(9@,1i)

:PORTAL_4312
16@ += 90.0
17@ += 180.0
9@(9@,1i) = Object.Create(#TEC9, 6@, 7@, 8@)
11@(9@,1i) = Object.Create(#TEC9, 0.0, 0.0, 0.0)
0453: set_object 9@(9@,1i) XY_rotation 16@ 180.0 angle 18@
0453: set_object 11@(9@,1i) XY_rotation 16@ 18@ angle 180.0
0750: set_object 9@(9@,1i) visibility 0
0750: set_object 11@(9@,1i) visibility 0
Object.CollisionDetection(9@(9@,1i)) = False
Object.CollisionDetection(11@(9@,1i)) = False
Object.SetImmunities(9@(9@,1i), 1, 1, 1, 1, 1)
Object.SetImmunities(11@(9@,1i), 1, 1, 1, 1, 1)
Object.KeepInMemory(9@(9@,1i)) = True
Object.KeepInMemory(11@(9@,1i)) = True
0400: store_coords_to 0@ 1@ 2@ from_object 9@(9@,1i) with_offset 0.0 100.0 0.0
06D5: 13@(9@,1i) = create_racing_checkpoint_at 6@ 7@ 8@ point_to 0@ 1@ 2@ type 3 radius 1.0
0A8D: 0@ = read_memory 13103464 size 4 virtual_protect 0
0A8D: 1@ = read_memory 13103468 size 4 virtual_protect 0
0A8D: 2@ = read_memory 13103472 size 4 virtual_protect 0
if and
0045:   0@ == 6@ // (float)
0045:   1@ == 7@ // (float)
0045:   2@ == 8@ // (float)
else_jump @PORTAL_4736
if
 9@ == 1
else_jump @PORTAL_4702
0A8C: write_memory 13103456 size 4 value -1056997376 virtual_protect 0

:PORTAL_4702
if
 9@ == 2
else_jump @PORTAL_4736
0A8C: write_memory 13103456 size 4 value -1073708801 virtual_protect 0

:PORTAL_4736
0A8D: 0@ = read_memory 13103520 size 4 virtual_protect 0
0A8D: 1@ = read_memory 13103524 size 4 virtual_protect 0
0A8D: 2@ = read_memory 13103528 size 4 virtual_protect 0
if and
0045:   0@ == 6@ // (float)
0045:   1@ == 7@ // (float)
0045:   2@ == 8@ // (float)
else_jump @PORTAL_4881
if
 9@ == 1
else_jump @PORTAL_4847
0A8C: write_memory 13103512 size 4 value -1056997376 virtual_protect 0

:PORTAL_4847
if
 9@ == 2
else_jump @PORTAL_4881
0A8C: write_memory 13103512 size 4 value -1073708801 virtual_protect 0

:PORTAL_4881
if
 9@ == 1
else_jump @PORTAL_4919
018C: play_sound 1052 at 0.0 0.0 0.0

:PORTAL_4919
if
 9@ == 2
else_jump @PORTAL_4957
018C: play_sound 1054 at 0.0 0.0 0.0

:PORTAL_4957
9@ = 0
return

:PORTAL_4966
30@ = 1
27@ = 0

:PORTAL_4980
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_4995
if
  Actor.Defined(25@)
else_jump @PORTAL_5041
if
  not Actor.Driving(25@)
else_jump @PORTAL_5041
gosub @PORTAL_5350
jump @PORTAL_5069

:PORTAL_5041
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_4995

:PORTAL_5069
27@ += 256
 27@ > 35584
else_jump @PORTAL_4980
30@ = 2
27@ = 0

:PORTAL_5108
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_5123
if
  Car.Defined(25@)
else_jump @PORTAL_5153
gosub @PORTAL_5350
jump @PORTAL_5181

:PORTAL_5153
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_5123

:PORTAL_5181
27@ += 256
 27@ > 27904
else_jump @PORTAL_5108
30@ = 3
27@ = 0

:PORTAL_5218
0085: 25@ = 27@ // (int)
28@ = 0

:PORTAL_5233
if and
  Object.Exists(25@)
803B:   not  10@ == 25@ // (int)
803B:   not  11@ == 25@ // (int)
803B:   not  12@ == 25@ // (int)
803B:   not  13@ == 25@ // (int)
else_jump @PORTAL_5295
gosub @PORTAL_5350
jump @PORTAL_5323

:PORTAL_5295
25@ += 1
28@ += 1
 28@ > 127
else_jump @PORTAL_5233

:PORTAL_5323
27@ += 256
 27@ > 89344
else_jump @PORTAL_5218
return

:PORTAL_5350
if
 30@ == 1
else_jump @PORTAL_5397
04C4: store_coords_to 19@ 20@ 21@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_5397
if
 30@ == 2
else_jump @PORTAL_5444
0407: store_coords_to 19@ 20@ 21@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_5444
if
 30@ == 3
else_jump @PORTAL_5491
0400: store_coords_to 19@ 20@ 21@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_5491
Object.StorePos(9@(31@,1i), 19@, 20@, 21@)
if
04E6:   object 9@(31@,1i) near_point 19@ 20@ 21@ radius 10.0 10.0 10.0 flag 0
0AA1: return_if_false
if
 30@ == 1
else_jump @PORTAL_5582
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@

:PORTAL_5582
if
 30@ == 2
else_jump @PORTAL_5614
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@

:PORTAL_5614
if
 30@ == 3
else_jump @PORTAL_5646
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@

:PORTAL_5646
18@ += -1.0
0400: store_coords_to 16@ 18@ 17@ from_object 11@(31@,1i) with_offset 16@ 18@ 17@
if
 0.0 > 17@
0AA1: return_if_false
if
 30@ == 1
else_jump @PORTAL_5753
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5753
if
 30@ == 2
else_jump @PORTAL_5807
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5807
if
 30@ == 3
else_jump @PORTAL_5861
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 0.0 0.0 0.0
gosub @PORTAL_7995

:PORTAL_5861
0509: 17@ = distance_between_XY 16@ 18@ and_XY 0.0 0.0
if
  not 30@ == 2
else_jump @PORTAL_5923
if
 2.0 > 17@
0AA1: return_if_false
jump @PORTAL_5939

:PORTAL_5923
if
 1.0 > 17@
0AA1: return_if_false

:PORTAL_5939
if
 30@ == 1
else_jump @PORTAL_6588
0665: get_actor 25@ model_to 5@
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 20@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 20@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 23@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 19@ 23@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 20@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 20@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 23@ 21@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 22@ 23@ 24@
083D: get_actor 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_6588
if
 30@ == 2
else_jump @PORTAL_7237
5@ = Car.Model(25@)
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 20@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 20@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 23@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 19@ 23@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 20@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 20@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 23@ 21@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -1.0
  not 4.0 > 17@
else_jump @PORTAL_7888
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 22@ 23@ 24@
06A2: get_car 25@ velocity_in_direction_XYZ 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_7237
if
 30@ == 3
else_jump @PORTAL_7886
5@ = Object.Model(25@)
07E4: get_model 5@ dimensions_cornerA_to 19@ 20@ 21@ dimensions_cornerB_to 22@ 23@ 24@
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 20@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 20@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 23@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 19@ 23@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 20@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 20@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 23@ 21@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 22@ 23@ 24@
059F: get_object 25@ velocity_in_direction 16@ 17@ 18@
gosub @PORTAL_7929
if or
  not 17@ > -0.5
  not 0.5 > 17@
else_jump @PORTAL_7888

:PORTAL_7886
return

:PORTAL_7888
if
 30@ == 2
else_jump @PORTAL_7920
04FE: deflate_tire 5 on_car 25@
0699: set_car 25@ repair_tire 5

:PORTAL_7920
gosub @PORTAL_8081
return

:PORTAL_7929
0093: 29@ = integer 32@ to_float
29@ *= 0.0035
006B: 16@ *= 29@ // (float)
006B: 17@ *= 29@ // (float)
006B: 18@ *= 29@ // (float)
005B: 3@ += 16@ // (float)
005B: 4@ += 17@ // (float)
005B: 5@ += 18@ // (float)

:PORTAL_7995
0400: store_coords_to 16@ 17@ 18@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 16@ -= 3@ // (float)
0063: 17@ -= 4@ // (float)
0063: 18@ -= 5@ // (float)
0400: store_coords_to 16@ 18@ 17@ from_object 11@(31@,1i) with_offset 16@ 18@ 17@
return

:PORTAL_8081
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8161
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_8161
if
 30@ == 2
else_jump @PORTAL_8208
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_8208
if
 30@ == 3
else_jump @PORTAL_8255
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_8255
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
0@ *= -1.0
1@ *= -1.0
2@ *= -1.0
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8416
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 1.0 0.0

:PORTAL_8416
if
 30@ == 2
else_jump @PORTAL_8463
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 1.0 0.0

:PORTAL_8463
if
 30@ == 3
else_jump @PORTAL_8510
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 1.0 0.0

:PORTAL_8510
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= 1.0
21@ *= -1.0
0063: 19@ -= 0@ // (float)
0063: 20@ -= 1@ // (float)
0063: 21@ -= 2@ // (float)
0087: 4@ = 19@ // (float)
0087: 5@ = 20@ // (float)
gosub @PORTAL_11167
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_8718
04C4: store_coords_to 16@ 17@ 18@ from_actor 25@ with_offset 0.0 0.0 1.0

:PORTAL_8718
if
 30@ == 2
else_jump @PORTAL_8765
0407: store_coords_to 16@ 17@ 18@ from_car 25@ with_offset 0.0 0.0 1.0

:PORTAL_8765
if
 30@ == 3
else_jump @PORTAL_8812
0400: store_coords_to 16@ 17@ 18@ from_object 25@ with_offset 0.0 0.0 1.0

:PORTAL_8812
0063: 19@ -= 16@ // (float)
0063: 20@ -= 17@ // (float)
0063: 21@ -= 18@ // (float)
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= -1.0
21@ *= -1.0
0063: 19@ -= 0@ // (float)
0063: 20@ -= 1@ // (float)
0063: 21@ -= 2@ // (float)
0087: 18@ = 3@ // (float)
18@ += -90.0
0087: 16@ = 19@ // (float)
0087: 17@ = 20@ // (float)
02F6: 4@ = sine 18@ // (float)
02F7: 5@ = cosine 18@ // (float)
006B: 16@ *= 5@ // (float)
006B: 17@ *= 5@ // (float)
006B: 19@ *= 4@ // (float)
006B: 20@ *= 4@ // (float)
17@ *= -1.0
005B: 19@ += 17@ // (float)
005B: 20@ += 16@ // (float)
0087: 18@ = 3@ // (float)
0087: 4@ = 20@ // (float)
0087: 5@ = 21@ // (float)
gosub @PORTAL_11167
0087: 16@ = 3@ // (float)
16@ *= -1.0
16@ += 360.0
0087: 4@ = 19@ // (float)
0509: 5@ = distance_between_XY 20@ 21@ and_XY 0.0 0.0
gosub @PORTAL_11167
0087: 17@ = 3@ // (float)
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
if
 30@ == 1
else_jump @PORTAL_9208
04C4: store_coords_to 3@ 4@ 5@ from_actor 25@ with_offset 0.0 0.0 0.0

:PORTAL_9208
if
 30@ == 2
else_jump @PORTAL_9255
0407: store_coords_to 3@ 4@ 5@ from_car 25@ with_offset 0.0 0.0 0.0

:PORTAL_9255
if
 30@ == 3
else_jump @PORTAL_9302
0400: store_coords_to 3@ 4@ 5@ from_object 25@ with_offset 0.0 0.0 0.0

:PORTAL_9302
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
0400: store_coords_to 3@ 5@ 4@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
3@ *= -1.0
4@ *= -1.0
5@ *= -1.0
18@ += 180.0
if
 30@ == 1
else_jump @PORTAL_9497
18@ = Actor.Angle(25@)
16@ = Object.Angle(9@(31@,1i))
31@ *= -1
31@ += 3
17@ = Object.Angle(9@(31@,1i))
31@ *= -1
31@ += 3
0063: 18@ -= 16@ // (float)
005B: 18@ += 17@ // (float)
18@ += 180.0

:PORTAL_9497
if
 30@ == 1
else_jump @PORTAL_9556
083D: get_actor 25@ velocity_in_direction_XYZ 19@ 20@ 21@
0619: enable_actor 25@ collision_detection 0
083C: set_actor 25@ velocity_in_direction_XYZ 0.0 0.0 0.0

:PORTAL_9556
if
 30@ == 2
else_jump @PORTAL_9650
06A2: get_car 25@ velocity_in_direction_XYZ 19@ 20@ 21@
099A: set_car 25@ collision_detection 0
07D5: set_car 25@ velocity_in_direction_XYZ 0.0 0.0 0.0 rotation_velocitiesXY 0.0 0.0 unk 0.0
07DB: set_car 25@ rotation_velocity_XYZ 0.0 0.0 0.0 through_center_of_mass

:PORTAL_9650
if
 30@ == 3
else_jump @PORTAL_9729
059F: get_object 25@ velocity_in_direction 19@ 20@ 21@
Object.CollisionDetection(25@) = False
Object.Throw(25@, 0.0, 0.0, 0.0)
05A2: set_object 25@ rotation_velocity_about_an_axis 0.0 0.0 0.0 through_center_of_mass

:PORTAL_9729
0400: store_coords_to 19@ 21@ 20@ from_object 11@(31@,1i) with_offset 19@ 21@ 20@
19@ *= -1.0
20@ *= -1.0
20@ += 2.5
31@ *= -1
31@ += 3
if
 30@ == 1
else_jump @PORTAL_10370
if
003C:   $PLAYER_ACTOR == 25@ // (int)
else_jump @PORTAL_10018
31@ *= -1
31@ += 3
0400: store_coords_to 6@ 7@ 8@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
068D: get_camera_position_to 0@ 1@ 2@
0063: 6@ -= 0@ // (float)
0063: 7@ -= 1@ // (float)
0063: 8@ -= 2@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 6@ 8@ 7@
2@ *= -1.0
31@ *= -1
31@ += 3
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)

:PORTAL_10018
0470: 24@ = actor 25@ current_weapon
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 3@ 4@ 5@
0A96: 0@ = actor 25@ struct
0@ += 20
0A8D: 0@ = read_memory 0@ size 4 virtual_protect 0
0@ += 48
0A8C: write_memory 0@ size 4 value 3@ virtual_protect 0
0@ += 4
0A8C: write_memory 0@ size 4 value 4@ virtual_protect 0
0@ += 4
0A8C: write_memory 0@ size 4 value 5@ virtual_protect 0
Actor.Angle(25@) = 18@
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
0619: enable_actor 25@ collision_detection 1
083C: set_actor 25@ velocity_in_direction_XYZ 19@ 20@ 21@
if
003C:   $PLAYER_ACTOR == 25@ // (int)
else_jump @PORTAL_10370
0400: store_coords_to 0@ 1@ 2@ from_object 9@(31@,1i) with_offset 0@ 1@ 2@
Camera.SetPosition(0@, 1@, 2@, 0.0, 0.0, 0.0)
04C4: store_coords_to 0@ 1@ 2@ from_actor 25@ with_offset 0.0 0.0 0.5
Camera.PointAt(0@, 1@, 2@, 2)
wait 0
Camera.Restore

:PORTAL_10370
if
 30@ == 2
else_jump @PORTAL_10926
if
  Actor.InCar($PLAYER_ACTOR, 25@)
else_jump @PORTAL_10584
31@ *= -1
31@ += 3
0407: store_coords_to 6@ 7@ 8@ from_car 25@ with_offset 0.0 0.0 0.0
068D: get_camera_position_to 0@ 1@ 2@
0063: 6@ -= 0@ // (float)
0063: 7@ -= 1@ // (float)
0063: 8@ -= 2@ // (float)
0400: store_coords_to 0@ 2@ 1@ from_object 11@(31@,1i) with_offset 6@ 8@ 7@
2@ *= -1.0
31@ *= -1
31@ += 3
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)
005B: 0@ += 3@ // (float)
005B: 1@ += 4@ // (float)
005B: 2@ += 5@ // (float)

:PORTAL_10584
0939: attach_car 25@ to_object 9@(31@,1i) with_offset 3@ 4@ 5@ rotation 16@ 17@ 18@
0684: detach_car 25@ 0.0 0.0 0.0 collision_detection 1
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
19@ *= 0.015
20@ *= 0.015
21@ *= 0.015
099A: set_car 25@ collision_detection 1
07D5: set_car 25@ velocity_in_direction_XYZ 19@ 20@ 21@ rotation_velocitiesXY 0.0 0.0 unk 0.0
07DB: set_car 25@ rotation_velocity_XYZ 0.0 0.0 0.0 through_center_of_mass
if
  Actor.InCar($PLAYER_ACTOR, 25@)
else_jump @PORTAL_10926
0400: store_coords_to 0@ 1@ 2@ from_object 9@(31@,1i) with_offset 0@ 1@ 2@
Camera.SetPosition(0@, 1@, 2@, 0.0, 0.0, 0.0)
0407: store_coords_to 0@ 1@ 2@ from_car 25@ with_offset 0.0 0.0 1.0
Camera.PointAt(0@, 1@, 2@, 2)
wait 0
Camera.Restore

:PORTAL_10926
if
 30@ == 3
else_jump @PORTAL_11131
16@ += 180.0
069A: attach_object 25@ to_object 9@(31@,1i) with_offset 3@ 4@ 5@ rotation 16@ 17@ 18@
0682: detach_object 25@ 0.0 0.0 0.0 collision_detection 1
0400: store_coords_to 19@ 20@ 21@ from_object 9@(31@,1i) with_offset 19@ 20@ 21@
0400: store_coords_to 3@ 4@ 5@ from_object 9@(31@,1i) with_offset 0.0 0.0 0.0
0063: 19@ -= 3@ // (float)
0063: 20@ -= 4@ // (float)
0063: 21@ -= 5@ // (float)
Object.CollisionDetection(25@) = True
Object.Throw(25@, 19@, 20@, 21@)
05A2: set_object 25@ rotation_velocity_about_an_axis 0.0 0.0 0.0 through_center_of_mass

:PORTAL_11131
31@ *= -1
31@ += 3
018C: play_sound 1150 at 0.0 0.0 0.0
return

:PORTAL_11167
0509: 3@ = distance_between_XY 4@ 5@ and_XY 0.0 0.0
0073: 4@ /= 3@ // (float)
0073: 5@ /= 3@ // (float)
0509: 3@ = distance_between_XY 4@ 5@ and_XY 0.0 1.0
24@ = 0

:PORTAL_11232
3@ /= 2.0
006B: 3@ *= 3@ // (float)
0087: 5@ = 3@ // (float)
3@ *= -1.0
3@ += 1.0
01FB: 3@ = square_root 3@
3@ *= -1.0
3@ += 1.0
006B: 3@ *= 3@ // (float)
005B: 3@ += 5@ // (float)
01FB: 3@ = square_root 3@
24@ += 1
 24@ > 15
else_jump @PORTAL_11232
3@ *= 65536.0
3@ *= 180.0
3@ /= 3.141593
if
 4@ > 0.0
else_jump @PORTAL_11422
3@ *= -1.0
3@ += 360.0

:PORTAL_11422
return
PM
  Top
 

 
ZAZ  
Posted: Thursday, Aug 16 2012, 21:08
Quote Post


Kernlochbohrer
Group Icon
Group: Members
Joined: Jan 10, 2005

eu.gif

Member Award




QUOTE (Your_Girlfriend @ Thursday, Aug 16 2012, 21:48)
OK. So... I have an portal mod you all heard about and maybe you have it on your PC. So do I...
Well lets get to the problem: I have found an downloaded a portal gun mod. No it's not a CLEO it's a real portal gun from Portal game. The problem is that portal gun and portal CLEO don't really match. Portal gun replaces shotgspa but portal CLEO spawns tec9. I've been doing some modifications to the CLEO so it can use shotgspa but that didn't went really well. It spawns it but it doesn't shoot portals. I would be happy if someone looks trough the code and finds a problem and a solution.


you just gave another weapon but the script is full of such codes:
CODE
if
02D8:   actor $PLAYER_ACTOR current_weapon == 32
Users WebsitePM
  Top
 

 
Your_Girlfriend  
Posted: Thursday, Aug 16 2012, 21:25
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



So if I change the 32 to 27 it should work?


Should I change the 32@ = 0 as well?

This post has been edited by Your_Girlfriend on Thursday, Aug 16 2012, 21:29
PM
  Top
 

 
ZAZ  
Posted: Thursday, Aug 16 2012, 21:47
Quote Post


Kernlochbohrer
Group Icon
Group: Members
Joined: Jan 10, 2005

eu.gif

Member Award




QUOTE (Your_Girlfriend @ Thursday, Aug 16 2012, 22:25)
So if I change the 32 to 27 it should work?

you could find it out by yourself

QUOTE
Should I change the 32@ = 0 as well?

does it belong in any way to a weapon code?

can you read this:
actor $PLAYER_ACTOR current_weapon
02D8: is an opcode to check the actors current weapon
Users WebsitePM
  Top
 

 
Your_Girlfriend  
Posted: Thursday, Aug 16 2012, 21:49
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



Sorry I'm a noob. But thanks for the help will try to change the $PLAYER_ACTOR current_weapon value.
PM
  Top
 

 
Your_Girlfriend  
Posted: Thursday, Aug 16 2012, 22:07
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



Did that still doesn't shoot portals. Any ideas, maybe weapon.dat needs to be changed?
PM
  Top
 

 
UNRATED69  
Posted: Friday, Aug 17 2012, 01:20
Quote Post


suck my hammer
Group Icon
Group: Leone Family Mafia
Joined: May 20, 2010

pride.gif

XXXXX



http://pastebin.com/HyJLwxSQ

This works fine for me.
Users WebsitePMPlayStation Network
  Top
 

 
Your_Girlfriend  
Posted: Friday, Aug 17 2012, 11:54
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



It works!!! Only it shoots a bit inaccurate...
Is there a way to fix this?
But anyway thanks!
PM
  Top
 

 
SamJohnson98  
Posted: Friday, Aug 17 2012, 15:57
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jan 13, 2012

XXXXX



You should just rename the shotgspa.txd and shotgspa.dff to tec9.dff and tec9.txd If you want the icon just open the .txd file and rename shotgspaicon to tec9icon and the alpha to tec9icona. It's simple. Didn't you figure that out?
PM
  Top
 

 
UNRATED69  
Posted: Friday, Aug 17 2012, 17:44
Quote Post


suck my hammer
Group Icon
Group: Leone Family Mafia
Joined: May 20, 2010

pride.gif

XXXXX



QUOTE (Your_Girlfriend @ Friday, Aug 17 2012, 06:54)
It works!!! Only it shoots a bit inaccurate...
Is there a way to fix this?
But anyway thanks!

CODE
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 0.3 0.0 0.7


Changing the offsets in this line will change where the portal appears.
Users WebsitePMPlayStation Network
  Top
 

 
Your_Girlfriend  
Posted: Friday, Aug 17 2012, 20:55
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



So I should put everything to zero?
Because as I said I'm a noob about modding.
PM
  Top
 

 
Your_Girlfriend  
Posted: Saturday, Aug 18 2012, 23:08
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jul 30, 2012

cw.gif

XXXXX



QUOTE (SamJohnson98 @ Friday, Aug 17 2012, 15:57)
You should just rename the shotgspa.txd and shotgspa.dff to tec9.dff and tec9.txd If you want the icon just open the .txd file and rename shotgspaicon to tec9icon and the alpha to tec9icona. It's simple. Didn't you figure that out?

No. It wouldn't be the same. The way CJ holds shotgspa is great for portal. Tec9 is held whit one hand but shotgun whit two hands! That's why he put it as a shotgun.
PM
  Top
 

 
SamJohnson98  
Posted: Monday, Aug 20 2012, 01:40
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Jan 13, 2012

XXXXX



Ouh.. Then change the weapon.dat..
PM
  Top
 

 
UNRATED69  
Posted: Monday, Aug 20 2012, 19:49
Quote Post


suck my hammer
Group Icon
Group: Leone Family Mafia
Joined: May 20, 2010

pride.gif

XXXXX



QUOTE (Your_Girlfriend @ Friday, Aug 17 2012, 15:55)
So I should put everything to zero?
Because as I said I'm a noob about modding.

No, changing them all to zero would make it even more inaccurate. The first of the numbers, the 0.3, is the X offset from the player that portal is calculated from. Decreasing the number will move the portal to the left, while increasing it will move it to the right. The last number, 0.7, is the Z offset, and controls the up and down position of the portal. Increasing it will move it up, and decreasing it will move it down.

I chose those numbers because that seemed to make it just as accurate as the original for me, but if it seems inaccurate to you then changing the first and last numbers according to what I said above will allow to to fix it.

@SamJohnson- Changing weapon.dat/the weapon models would have no effect, as the original code checked for the animation of the Tec-9, and wouldn't work otherwise. So editing the code was required to do what was requested.
Users WebsitePMPlayStation Network
  Top
 

 

0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)

0 Members:

Topic Options Reply to this topicStart new topicStart Poll
Search topic for posted by (exact match)



 
IMG IMG