Thursday, February 21, 2013

Beta

Crimmor is ready for beta. I've messaged people that tested the proof of concept long ago, and a few builders. Since dropbox doesn't have unlimited bandwidth on accounts I don't want to post links for everyone and get the dropbox account temporarily locked, preventing people from downloading, if you are interested send me a message via Bioware Social, my profile is here:  http://social.bioware.com/2429179/ .

Monday, February 11, 2013

Bringing .max files into Gmax, without Max

You need 3DExplorer from http://dutch-boy.com/3De/ (version 1.8 or above), which will open .max files and allow you to save them as .3ds and .obj. Once they are in .3ds you need gmax scripts that can import the object into gmax. Fortunately someone made scripts for that. You need the 3ds importer v1.1 from http://pages.videotron.com/browser/ I found that page via the Natural Selection modding website, at http://forums.unknownworlds.com/discussion/95819

Tuesday, February 5, 2013

Summoning the Sound Ninja - a PlaySound fix

The PlaySound function puts a sound playing request into the queue of the target creature, which means it doesn't actually play the sound until the other actions in the queue happen. "But I want to play the sound now, not when and even if the queue finishes" you say?

http://nwn2.wikia.com/wiki/PlaySound mentioned using a scripthidden "sound ninja" to stand in and play a sound, but didn't have an implementation, and the suggested implementation looked like it hard coded the sound into the onSpawn script of the sound ninja, so you'd have to make a different ninja with a different script for each sound. So here you go, a generic sound ninja summoning version of PlaySound, this ninja does not require any scripts at all.

/*
    credit to kevL at http://social.bioware.com/forum/1/topic/164/index/15800566#15801095
   
 ga_play_sound replacement, summons the "sound ninja" creature to play sounds since
 playsound goes at end of action queue, so an npc may not play immediately
 for more see http://nwn2.wikia.com/wiki/PlaySound

 Note that the sound ninja does not need to have any scripts on it at all, but "Disable AI
 while hidden" must not be checked.

 Also note the string sSound is not the tag of a sound object, but the name of the actual
 wav sound file to play

*/
#include "ginc_param_const"


void kL_PlayNinja(string sSound, object oSoundNinja, float fDelay)
    {
    DelayCommand(fDelay, AssignCommand(oSoundNinja, PlaySound(sSound)));
    fDelay += 10.f;
    DelayCommand(fDelay, DestroyObject(oSoundNinja));
    }   

void main(string sSound, string sTarget, float fDelay)
    {
    object oTarget = GetTarget(sTarget, TARGET_OWNER);//
    location lTarget = GetLocation(oTarget);
    object oSoundNinja = CreateObject(OBJECT_TYPE_CREATURE, "sh_sound_ninja", lTarget);
    if (GetIsObjectValid(oSoundNinja))
        {
        DelayCommand(0.1f, kL_PlayNinja(sSound, oSoundNinja, fDelay));
        }
    }

Friday, February 1, 2013

January Update : Part 2

Unfortunately I caused myself lots of problems switching from a single module campaign to a six module campaign. I lost my up to date journal, since I had it at the campaign level and the journal importer/exporter utility only handles module level journals. I had to go to a backup journal. Updating mapnotes and door lock status doesn't work when the targets are now in different modules either :-). The modules were also confused about what their campaign folder was, even after I used the campaign editor to set things. I had to take my old campaign folder and move it out of the campaigns folder entirely, even though the modules were supposedly not referring to it. Even the test module was confused about what campaign folder it should use.


So now I'm fixing all the things I broke in my bungled conversion to a six module campaign. While I had played Crimmor to completion in December, I'm currently not able to. Not to worry though, I've fixed lots of other bugs that were present when I was able to play all the way through.

In this image, the pc was tasked with forging some orders for a caravan company. This was made complicated by the fact the merchant representative of the company is standing behind the counter, and there is a locked door behind/next to him where the offices and the order book is.

Solutions available:

1.Pickpocket the door key from the merchant, then use that key when the merchant isn't looking in order to get inside the office (PRR ownership scripts mean the merchant "owns" the door and pays attention to attempts to pick it/knock it down).
2. Intimidate or bluff the merchant into giving you the key. Now that you "legitimately" have access to the door, the merchant doesn't pay any attention to you using the door.
3. Use the special Hidden Theurgy ability if available to cast a suitable spell on the merchant, so he will willingly give you the key.
4. Kill him and take the key. How gauche. Plus the merchant will fight back, and stands a decent chance of killing the thief.

The PC is a thief/wizard and has Hidden Theurgy. He knows a relevant spell for use on the merchant, in this case Charm Person, and passed the skill checks (Concentration, Sleight of Hand, and Spellcraft) that allowed him to cast it on the merchant during conversation without the merchant knowing.

Charmed, the merchant thus willingly gave him the key, and the thief is in the offices.

Now the player has to actually forge the orders in the books. He can try his penmanship via skill and stat check, cast a True Strike he has memorized in order to temporarily give himself perfectly matching penmanship, or simply call the merchant he charmed in order to have the merchant change his own orders.