Merchant and item container windows close randomly
randomguy101
Member Posts: 6
This is a very weird bug that only happens in my module. Whenever I open a merchant window (go to buy/sell something from a merchant) or open any item container, the window closes randomly within 3-5 seconds. I tested this on the standard toolset merchants/containers and it still happens. Even tested it using the base "open merchant" wizard script.
However when I create a brand new module and try it, the bug isn't there.
My main module has no haks besides my music hak but I had the bug before I created that hak. How do I fix this?
However when I create a brand new module and try it, the bug isn't there.
My main module has no haks besides my music hak but I had the bug before I created that hak. How do I fix this?
0
Comments
If so check the module OnAcquireItem and OnUnAcquireItem scripts in module properties
The only module property script I've edited is OnClientEnter and I didn't even touch the original code of it. Maybe there's some heartbeat script thats messing with everything. Is there a way to revert everything to the base scripts?
void main()
{
BeginConversation("cnv_intro_2", GetFirstPC());
}
Is it me or should this bug never be happening in the first place? Are heartbeat scripts from other areas supposed to be running?
When there's no PC in an area, in some circumstances idle creatures acquire a low AI level which can delay new actions, but, for example, BeginConversation executes immediately.
Other objects e.g. placeables do not slow down when no one's around.
Often this doesn't use much resource or break things, but where there is very heavy heartbeat processing, you may want to count the number of PCs in the area and tell heartbeat scripts to do nothing if there are none.
A classic example is wandering citizens and monsters - in a large module, performance and other issues are often improved if they are destroyed when there are no PCs and respawned when one enters.