I got a bit of an issue. There is an area in which I need a conversation to happen. Now normally, I would use a trigger. However, the area is bugged. In game it looks fine, but in the toolset the terrain is not visible. Also, I cannot place anything new on this area. It just won’t be placed. So I need to start a conversation via another way. I was thinking perception but I never tried something like that. Any ideas?
You can also use the OnHeartbeat handler for this purpose.
Here is how the OnHeartbeat script of your creature should look like:
// custom heartbeat
if (GetAILevel() == AI_LEVEL_VERY_LOW) return;
if (!IsBusy(OBJECT_SELF) && GetCommandable(OBJECT_SELF) && !GetLocalInt(OBJECT_SELF, "bConvoDone"))
object oPC = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC, OBJECT_SELF, 1, CREATURE_TYPE_PERCEPTION, PERCEPTION_SEEN, CREATURE_TYPE_IS_ALIVE, TRUE);
ActionStartConversation(oPC); // <- bConvoDone is set to 1 in the conversation
The OnPerception handler solution is quite similar.
I’m curious, is this for RoE or is this a new project you are working on?
It’s for RoE. It happened in the Hades area. I added some content since we last talked as we both figured it looked kinda empty.
I guess the elephant in the room for me is why is the area bugging in the toolset in the first place. I’d love to take a look at that issue and I think I still have access to the pCloud files. Would you mind updating those files so I can take a look at that area?
Absolutely fine with it. I will update the module later today. In the beginning I was afraid that the area is corrupted or something else on a catastrophic scale. But it runs fine in game. I’ll let you know when I update the files on the cloud.
Is it just the ext_hades area that is bugging? Or is it also the other areas in the 16_Hades module folder?
Only the ext_hades (hopefully :D)
Have you tried the script I provided above? Was my answer helpful for you or maybe you managed to find your own solution?
Copy the area with terracoppa, it will likely fix the bugged area.
I got files, found the problem. I sent the fix via PM.
I haven’t tried it yet, but I will just in case I need it at a later project. For now, the area is fixed so I don’t need the workaround.
I only used terracoppa once and I swore to never go back down that road
for future users with the same or a similar problem it would be really helpful if you could describe what you did to fix the area. thank you.
It was a corrupt TRN file for the area (the file size was 0). Luckily, a backup was available. So we replaced the corrupt file with the good one.
As Travus said. I suspected a corruption from the start and thankfully it was the TRN file and not the TRX file as more work would be needed to bring it up to current standards.