You are not logged in.
Pages: 1
Я нарыл некую информацию о том, что в бета-версии игры при убийстве пешехода приезжали репортёры и делали репортаж об этом. Там ещё про возможность со столбами было, но это не важно. Важно то, что состряпанный мною код не работает полностью:
{$CLEO .cs}
0000: NOP
0662: "SCRIPT NEWS VAN CRIME REPORTS"
0662: "BY SW[EE]T!!!"
:NCRIR
thread "NCRIR"
:NCRIR_1
wait 0
0AB5: store_actor $PLAYER_ACTOR closest_vehicle_to $_UNUSED closest_ped_to 0@
if
056D: actor 0@ defined
jf @NCRIR_1
if
not actor.Driving(0@)
jf @NCRIR_1
:NCRIR_2
wait 0
if and
0105: actor $PLAYER_ACTOR near_actor 0@ radius 5.0 5.0 2.0 sphere 0 on_foot
actor.Dead(0@)
jf @NCRIR_1
:NCRIR_3
wait 0
model.Load(#NEWSVAN)
model.Load(#BFYBU) // 148 ID
038B: load_requested_models
:NCRIR_4
wait 0
if and
model.Available(#NEWSVAN)
model.Available(#BFYBU)
jf @NCRIR_4
:NCRIR_5
wait 500
actor.StoreDeadActorPos(0@,1@,2@,3@)
actor.StoreDeadActorPos(0@,13@,14@,15@) // for reporter's
actor.StoreDeadActorPos(0@,16@,17@,18@) // for camera man
17@ -= 5.0
16@ -= 2.0
actor.StorePos($PLAYER_ACTOR,9@,11@,12@)
2@ -= 150.0
1@ -= 50.0
02C1: store_to 4@ 5@ 6@ car_path_coords_closest_to 1@ 2@ 3@
6@ -= 5.0
7@ = car.create(#NEWSVAN,4@,5@,6@)
car.DoorStatus(7@,4)
0129: 8@ = create_actor_pedtype 23 model #MALE01 in_car 7@ driverseat
01C8: 10@ = create_actor_pedtype 23 model #BFYBU in_car 7@ passenger_seat 0 // 9@ - reserved
wait 100
:NCRIR_6
wait 0
if or
not car.Wrecked(7@)
not actor.Dead($PLAYER_ACTOR)
jf @NCRIR_5
car.DriveTo(7@,9@,11@,12@)
:NCRIR_7
wait 0
if or
not car.Wrecked(7@)
not actor.Dead($PLAYER_ACTOR)
jf @NCRIR_5
if
01AD: car 7@ sphere 0 near_point 9@ 11@ radius 10.0 10.0
jf @NCRIR_7
:NCRIR_8
wait 0
02D4: car 7@ turn_off_engine
05CD: AS_actor 10@ exit_car 7@
05CD: AS_actor 8@ exit_car 7@
:NCRIR_9
wait 0
if
not actor.InCar(10@,7@)
jf @NCRIR_8
05D3: AS_actor 10@ goto_point 13@ 14@ 15@ mode 4 -1 ms // versionA
05D3: AS_actor 8@ goto_point 16@ 17@ 18@ mode 4 -1 ms // versionA
:NCRIR_10
wait 0
if and
02A0: actor 10@ stopped
02A0: actor 8@ stopped
jf @NCRIR_9
// reporters doing stuff
:NCRIR_11
wait 2000
if and
not actor.Dead(8@)
not actor.Dead(10@)
not car.Wrecked(7@)
not actor.InCar($PLAYER_ACTOR,7@)
jf @NCRIR_11_a
car.DoorStatus(7@,0)
jump @NCRIR_12
:NCRIR_11_a
wait 0
actor.DestroyInstantly(8@)
actor.DestroyInstantly(10@)
car.Destroy(7@)
model.Destroy(#NEWSVAN)
model.Destroy(#BFYBU)
wait 1000
jump @NCRIR_1
:NCRIR_12
wait 0
05CB: AS_actor 8@ enter_car 7@ as_driver 10000 ms
05CB: AS_actor 10@ enter_car 7@ as_driver 10000 ms
:NCRIR_13
wait 250
if and
actor.InCar(8@,7@)
actor.InCar(10@,7@)
jf @NCRIR_12
0ABF: set_vehicle 7@ engine_state_to 1
:NCRIR_14
car.RemoveReferences(7@)
actor.RemoveReferences(10@)
actor.RemoveReferences(8@)
model.Destroy(#NEWSVAN)
model.Destroy(#BFYBU)
wait 1000
jump @NCRIR_1При попытке вставить после
7@ = car.create(#NEWSVAN,4@,5@,6@) car.DoorStatus(7@,4)
следующее
marker.createabovecar(25@,7@)
игра тупо вылетает. Из-за чего такое может быть? И есть-ли в скрипте ошибки, так как скрипт писался в сонном бреду. Спасибо.
Offline
0AB5: store_actor $PLAYER_ACTOR closest_vehicle_to $_UNUSED closest_ped_to 0@
убери $_UNUSED. можно поставить 0@
0105: actor $PLAYER_ACTOR near_actor 0@ radius 5.0 5.0 2.0 sphere 0 on_foot
зачем эта проверка, если ты все равно ищешь ближайшего актера.
0129: 8@ = create_actor_pedtype 23 model #MALE01 in_car 7@ driverseat
модель #MALE01 не нужно загружать?
23 SPECIAL
уверен, что нужен именно тип 23, а не 4?
В логике кода увы разобраться сложно из-за нагромождения джампов и меток. Поддержку думера
Offline
Навели шороху, сказали много чего не нужного и к тому же, не помогли ни грамма. В логике кода разобраться не трудно, если прочитать первые слова темы: "при убийстве педа игроком, приезжают телевизионщики". Всё что приведено ниже, не является причиной вылета.
Offline
Sw[ee]t
вmarker.createabovecar(25@,7@)
поменяй 25 и 7 местами
точно не помню, но вроде нужно наоборот писать
Что за ерунду написал? Всё верно, здесь, 7 - хендл машины, 25 - хендл маркера.
Offline
Pages: 1