ProjectsWhat's NewDownloadsCommunitySupportCompany
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
Serious problem with my all.spawn - corrupt?

« Previous 10 events | 1 2 3 | All Messages
Posted by/on
Question/AnswerMake Newest Up Sort by Descending
  20:52:18  28 October 2013
profilee-mailreply Message URLTo the Top
bamah
Senior Resident
 

 
On forum: 02/10/2008
 

Message edited by:
bamah
10/28/2013 20:55:49
Messages: 911
The object is duplicated somewhere in the all.spawn or script that spawns an LC conditionally or on game load.

Just open a group of scripts in notepad and search for a duplicate object ID, are you sure it's 9004 and not something else. If you feel it's the all.spawn just use the version prior to the addition that's causing a CTD. An add one or a few objects your sure about. I never add more than 3 at a time....been there done that error.
  23:44:32  28 October 2013
profilee-mailreply Message URLTo the Top
NatVac
Senior Resident
 

 
On forum: 06/15/2007
Messages: 4302
This might be the duplication bamah is talking about:

>> name = exit_to_agr_from_esc
with
>> 9004 = "exit_to_agr_from_esc"

I don't know of any instance where the level_changer's object name was the same as the name assigned to the story_id. I don't even think the named story_id instances in game_story_ids.ltx are needed unless you want to refer to them by name -- level_tasks.script certain doesn't.

Perhaps the game parses game_story_ids.ltx first, then finds an object with the same name and same story_id. Or the other way around, but you have a duplicate.

I dynamically spawn several LCs in ZRP without any references in game_story_ids.ltx, and they are still marked via level_tasks.script. No problems there.

On top of that, there can be typos in the names in game_story_ids.ltx, like gar_exir_to_escape. I think the names are just handles to make it easier to reference a story_id. There are no helper functions that use the name and I didn't see any of the names I checked used anywhere in the game except lua_help.script which is not used by the game.

This yields a couple of things to try: use a name for xxxx = "lc_id_name" that's different from the object's name = "lc_name", or just remove it altogether.
  20:28:25  29 October 2013
profilee-mailreply Message URLTo the Top
FatalFunnel
(Senior)
 
On forum: 11/07/2011
 

Message edited by:
FatalFunnel
10/29/2013 20:49:53
Messages: 133

---QUOTATION---
This might be the duplication bamah is talking about:

>> name = exit_to_agr_from_esc
with
>> 9004 = "exit_to_agr_from_esc"

I don't know of any instance where the level_changer's object name was the same as the name assigned to the story_id. I don't even think the named story_id instances in game_story_ids.ltx are needed unless you want to refer to them by name -- level_tasks.script certain doesn't.

Perhaps the game parses game_story_ids.ltx first, then finds an object with the same name and same story_id. Or the other way around, but you have a duplicate.

I dynamically spawn several LCs in ZRP without any references in game_story_ids.ltx, and they are still marked via level_tasks.script. No problems there.

On top of that, there can be typos in the names in game_story_ids.ltx, like gar_exir_to_escape. I think the names are just handles to make it easier to reference a story_id. There are no helper functions that use the name and I didn't see any of the names I checked used anywhere in the game except lua_help.script which is not used by the game.

This yields a couple of things to try: use a name for xxxx = "lc_id_name" that's different from the object's name = "lc_name", or just remove it altogether.
---END QUOTATION---



Thanks for the clarification. The SDK portal and the threads I have read on this subject didn't really provide as much as an in-depth summary of this sort of thing as you've given here.

It seems to be giving me the same error on startup, even after deleting the LC names from game_story_ids.ltx, do I even need the story_ids for them in their all.spawn sections themselves?
  23:48:38  30 October 2013
profilee-mailreply Message URLTo the Top
FatalFunnel
(Senior)
 
On forum: 11/07/2011
Messages: 133
So if what you said is correct than it is also possible to avoid editing them into the all.spawn entirely and spawn them via script, right?
  15:17:09  25 November 2013
profilee-mailreply Message URLTo the Top
NatVac
Senior Resident
 

 
On forum: 06/15/2007
Messages: 4302
>> do I even need the story_ids for them in their all.spawn sections themselves?

You only need them for quick access to mark them with the segmented circle; see your code in add_lchanger_location() in scripts\level_tasks.script. You could iterate over all objects and match on name or section to place a spot, though.

---QUOTATION---
So if what you said is correct than it is also possible to avoid editing them into the all.spawn entirely and spawn them via script, right?

---END QUOTATION---


While you can always spawn them via script -- with the added benefit of only spawning certain ones when sufficient progress is achieved -- the problem here is more likely what bamah is talking about. Somehow your code is creating an object with the same story_id as another, or the same object is being created twice.

This second possibility is unlikely in an all.spawn object, so I would try using a different story_id, perhaps something in the range of 10000 to 11000 for instance. You would want to do this because it would be easy to add the spot the normal way.

It could be that some script is dynamically creating objects in a loop, with story_id values taken from a range of numbers which includes your story_id of 9004.
 
Each word should be at least 3 characters long.
Search:    
Search conditions:    - spaces as AND    - spaces as OR   
 
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
 

All short dates are in Month-Day-Year format.


 

Copyright © 1995-2021 GSC Game World. All rights reserved.
This site is best viewed in Internet Explorer 4.xx and up and Javascript enabled. Webmaster.
Opera Software products are not supported.
If any problem concerning the site functioning under Opera Software appears apply
to Opera Software technical support service.