Tuesday, March 23, 2010

Feeling stabby again

Well, if just posting about a frustration is going to get me answers as quickly as my last post:

Another one of those problems that just appeared out of seemingly nowhere. This is seperate from the barkstring conversation issue I posted.

New area transition triggers for module transition in my campaign have broken (ie: they used to work, now they don't). They either:
a) don't work at all. They player enters them and nothing happens, or the transition autosave happens but they don't transition.
b) work, but send the player to the module start point, not the designated waypoint.

I've tried several versions of area transitions. I've used the standard new area transition trigger, as well as generic triggers with the ga_olmap_load script and the ga_load_mod script.

The destination waypoints exist and I have confirmed their tag names as well as the module names being referenced.

Has anyone else run across this? Wyrin commented to my previous post that he's started to see some of this behavior. This issue is preventing me from releasing an updated test version of Path of Evil.


  1. you're a month or so ahead of me I think and so I've spotted a little of this behaviour but not tested fully. if I get time I'll dig around some more and let you know what I find

    - Wyrin

  2. Hi Kamal

    Have you got some code interupting the transition in a heartbeat (or on enter, etc) somewhere?

    Also, is the waypoint unique. (I have accidentally had more than one with the same tag before.)

    If I get to this before you resolve it, I will have a look myself.


  3. This comment has been removed by the author.

  4. From Knightmare on the official forums

    void main()
    LoadNewModule("module_name", "waypoint_tag");

    So a new script for each transition. It shouldn't be that way, it should be a generic script getting variables stored on the trigger. But it did work.

    Here is my test campaign if anyone would like to test though. A campaign of two modules, each with a single area, single waypoint and transition trigger in each.

  5. Hi Kamal,

    Are you saying you have fixed the problem?

    I'm not sure what you are offering the test campaign for?

    You say, "But it did work" ... Do you mean that it did used to work (past tense and does not anymore) and it still needs testing/fixing, or this function "did work" (as in resolve your issue) and you have a test campaign showing it?

    Please clarify. :)


  6. Using the code _Knightmare_ provided, I am able to get the module transitions to work. However, this requires making a seperate script for every module transition (even if it is only copy paste and replace the variables with different module/waypoint names). But I can deal with that since it does seem to consistently work.

    It's not supposed to work that way though, the general area transition trigger is supposed to read variables off the trigger for module transition. Doing the module transition the "correct" way was and still is broken for me.

    I provided the test campaign for experimenting with different ways to do module transition, since there are several default scripts that can do module transition, ga_load_mod, ga_olmap_visit etc.

  7. Hi Kamal,

    I have only ever tested one module jump with the following code extract:

    // E.g. If sTargetDestination == TheDeep, then the waypoint would be MWP_TheDeep in the Module named TheDeep
    string sModule = sTargetDestination; // NB: MAP TRAVEL DATA MUST BE SET NEW IN NEW MODULE
    LoadNewModule(sModule, "MWP_" + sTargetDestination);

    As you can see, I use the same "variable" to load both the module and the waypoint it should travel to with the MWP_ in front of the same variable to differentiate.

    Not having more than one other module to test, I cannot say I experienced your problem, but maybe doing it something like the above may help?

    Also, don't have any gaps in the name of your module. i.e. Use tags like "TheDeep" or "The_Deep", but DO NOT USE "The Deep".

    Let me know if that helped.


  8. Hi Again,

    Actually, I just realised that the function *does* refer to the *name* of the module and not the tag. I know I said "name" in the above post, but had actually been thinking "tag". Therefore, not having gaps in the name may be an issue, but may still be worth checking, just in case it is something like that.


  9. Hi Kamal,

    OK, I downloaded your test campaign and noticed even before I could even get in:-

    1) Campaign needed naming.
    2) Start module needed setting in campaign editor.

    However, this may have been intentional for testers to alter. Anyway, I also noticed:-

    3) Whenever I updated the campaign, I needed to completely come out of the NWN game (back to desktop and start again) before any campaign alterations would be recognised.changes

    Then, after checking out the modules, I observed (but may be wrong):-

    4) In both test areas, you were relying on variables set on triggers without any code referencing them! You cannot set variables under any old variable name and expect the engine to pick up on it. At least, certainly not that I am aware. You would have to know the specific variable name to do that, and I reckon it would not be accessible via the builder accessible settings anyway.

    In test1 you are trying to use a function with variables being passed to it, but as if the trigger automatically passed those variables into it! You have to code the OnEnter part of the trigger to access the variables on the trigger and then pass them to the function.

    Are you sure that your transitions worked this way before?

    I have never seen coding this way and am surprised you ever had it work. Unless I am missing something really big here. ;)

    I think I will open up your mod and take a look at it, just to see what you did in the one I am currently playing/testing. (I have not had to transition to another module yet.)

    Also ...

    5) As far as I am aware, you can only use the "basic" transition properties of a trigger if they relate to a waypoint/door in the same module. In other words, transitioning to another module requires extra coding, but not a lot more ... just different.

    If you are struggling to understand what I wrote here, let me know and I will give you an example in your own mod if I can.


  10. Hi,

    Please help me out ... I am trying to find a module load script/trigger in your mod ... where is the trigger/script in your "poe_intro" module that points to the next module (whatever that may be)?

    It's like looking for a needle in a haystack. ;)



  11. Hi Kamal,

    What a tangled web I have started to fall into ... As I was trying to search for "world travel" code, I also noticed that you have not included the world map TGA file, so no world map will show (as far as I can see). Unless you can tell me where it is located, but I have searched in as many places as I thought it might be.

    Sorry to be the bearer of bad news.


  12. I left the transition code out of the test module. (actually, I think there are a couple of test scripts that could be assigned to the trigger) It's just set to experiment with different ways to do a module transition. There is no world map in the test module. I just wanted to test using the new area transition trigger. The test campaign is something I threw together in 15 minutes or so, so I'm sure there are stupid errors in naming it. I just ran it out of the toolset.

    Yes. Triggers with variables on them passing those to the code worked. I tested every module transition in the campaign before my tester release.

    poe_intro just uses a transition in conversation. It works fine.

    As I said, I consider the issue "solved" as far as I'm concerned, since I can write scripts for each transition. So please don't spend any more time on it.

  13. Hi Kamal,

    I am talking about the world map in your module that I am playing/testing - not the test campaign. There does not appear to be a world map TGA file in there.

    Good to hear its solved. :)


  14. eh? The map projections like
    http://3.bp.blogspot.com/_Arkur0fkYgs/S2Ln7LRG0wI/AAAAAAAAAbk/hfqnvoo1f-k/s1600-h/NWN2_SS_012810_200815.jpg ?

    The textures for the maps are map_se_faerun.tga , map_ne_faerun.tga etc. I just checked and they are in the module folders so they should be in there.

    vfx don't show on the minimap unfortunately. Or at least I can't get them to.

    I'll have a new build sometime this weekend. You've reached the overland map, so you're probably been wondering why you can't enter anything before you saw this blog post... :-) I didn't even know you were testing, I guess you're going to drop the full buglist on me at once since there's no updates other than mine to my wiki. :-) Hopefully you're enjoying it so far.

  15. Hi Kamal,

    Actually, I have *not* reached your overland map yet. I only mentioned it because I was trying to resolve your other issue and felt it may have some transitions I could look at. ;)

    However, I realise now that you areusing SoZ overland map and not earlier versions and so my point is moot. Even though you appear to have started to use the Map Editor, it is obviously something you did not end up using. My bad!

    In all fairness, although I have been playing on and off, I have not made any notes as it is not an easy mod to "test". There was a strange quest inconsistency with a house with some spiders that needed clearing. I found the house, killed the spiders and then found the chap who wanted them cleared afterwards. The conversation appeared to be all over th eplace. :(

    I will try to play some more, as I am looking forward to reaching the overland map and seeing it in action, but I cannot promise how much time I can commit to it. :( I have so much to do with my own module of late, that any playing time is very slim.



  16. I wouldn't worry. You'll need the new version I will post this weekend sometime. It fixes the module and area transition issues on the world maps that were the subject of my last two blog posts.