• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

Inez Diaz' Tool

Indeed, I believe Pieter is correct. 3DSMax will ONLY load the geometry from a Maya model, the locators are not actually part of the geometry, but are part of the additional information built into the model file format by Maya, similar to designating the name of the texture file and things like that.

Cap'n Drow
 
Uhm. Hm.

Can i trace my current position on demand?

Edit:
I found this cute line here:
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->trace("rld,loc,"+xx+",0,"+y+","+xz+",0,1,0,"+zx+",0,"+zz+","+x+","+y+","+z+",1,0,0,0,0,0,0,0,0,");<!--c2--></div><!--ec2-->

But how to get the position of the main character?
 
I think someone should work on adding a console function to CoAS.
Basically what that does is to allow you to press a button and execute the code you set up in a file before.
So you need to set up a button to press and hook that up to the executing of a new code file.
You might want to refer to how it's handled in the Build Mod. You can find our code files <a href="http://www.piratesahoy.net/build/temp/pb_code.zip" target="_blank">here</a>.

Without some way of executing code while you're in the game, I don't see how you can trace your position while in the game. <img src="style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":?" border="0" alt="unsure.gif" />
 
<!--quoteo(post=326370:date=Jun 8 2009, 08:50 AM:name=Pieter Boelen)--><div class='quotetop'>QUOTE (Pieter Boelen @ Jun 8 2009, 08:50 AM) <a href="index.php?act=findpost&pid=326370"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I think someone should work on adding a console function to CoAS.
Basically what that does is to allow you to press a button and execute the code you set up in a file before.
So you need to set up a button to press and hook that up to the executing of a new code file.
You might want to refer to how it's handled in the Build Mod. You can find our code files <a href="http://www.piratesahoy.net/build/temp/pb_code.zip" target="_blank">here</a>.

Without some way of executing code while you're in the game, I don't see how you can trace your position while in the game. <img src="style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":?" border="0" alt="unsure.gif" /><!--QuoteEnd--></div><!--QuoteEEnd-->

Cheating ;-) I was up to put the codeline into the gamemenu startup function. so i would only have to open the mainmenu <img src="style_emoticons/<#EMO_DIR#>/rolleyes.gif" style="vertical-align:middle" emoid=":rolleyes:" border="0" alt="rolleyes.gif" />

EDIT:
Thank you for the directory. I was able the extract the needed codelines :-D
 
That's a pretty smart idea, actually. Still, a proper console is better. <img src="style_emoticons/<#EMO_DIR#>/icon_mrgreen1.gif" style="vertical-align:middle" emoid=":cheeky" border="0" alt="icon_mrgreen1.gif" />
 
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->void SetCrewOnDeck(string deck)
{
    ref ch;
    int r,i;
    string m;
    
    ref chr = GetMainCharacter();
    
    int nShipType = GetCharacterShipType(chr);
    ref shp = GetRealShip(nShipType);
    
    int cqt = GetCrewQuantity(chr);
    int max = shp.MaxCrew;
    int mx = 5;
    
    if(deck=="Deck_Near_Ship_Low"){
        mx = 10;
    }
    if(deck=="Deck_Near_Ship_Medium"){
        mx = 15;
    }
    if(deck=="Deck_Near_Ship_Big"){
        mx = 20;
    }
    
    int crw = (mx/max)*cqt;
        
    for (i=0; i < crw; i++){
        m = "Chard";
        r = rand(4);
        if(r == 2){ m = "Chard2"; }
        if(r == 3){ m = "Chard3"; }
        if(r == 4){ m = "Chard3a"; }
        
        ch = GetCharacter(NPC_GenerateCharacter("Rand_"+i, m, "man", "man", 1, ENGLAND, 1, false));
        SetFantomParamFromRank(ch, 1, true);
        PlaceCharacter(ch, "goto", chr.location);
    }
}<!--c2--></div><!--ec2-->

Its not pretty, but can an anyone say me why that doesn't work? I have no error messages -.-
 
What happens if you just use the following?<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->void SetCrewOnDeck(string deck)
{
    ref ch = GetCharacter(NPC_GenerateCharacter("Rand_1", "Chard", "man", "man", 1, ENGLAND, 1, false));
    PlaceCharacter(ch, "goto", chr.location);
}<!--c2--></div><!--ec2-->
Just to check that the character creation code is doing anything at all.
Personally I'm not sure exactly what PlaceCharacter does and always use the ChangeCharacterAddress line instead. <img src="style_emoticons/<#EMO_DIR#>/dunno.gif" style="vertical-align:middle" emoid=":shrug" border="0" alt="dunno.gif" />
 
Hello :)

<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->void SetCrewOnDeck(string deck)
{    
    ref ch;
    string m;
    string models[20];
    
    ref chr = GetMainCharacter();
    int nShipType = GetCharacterShipType(chr);
    ref shp = GetRealShip(nShipType);
    float max = shp.MaxCrew;
    float cqt = GetCrewQuantity(chr);
    float mx = 5.0;
    
    models[0] = "Chard";
    models[1] = "Isterling";
    models[2] = "Chard3";
    models[3] = "Chard3a";
    models[4] = "GenresBag2";
    models[5] = "pirate_8";
    models[6] = "GenresChest1";
    models[7] = "Chard2";
    models[8] = "pirate_4";
    models[9] = "pirate_1";
    models[10] = "pirate_2";
    models[11] = "pirate_3";
    models[12] = "Ostin";
    models[13] = "pirate_5";
    models[14] = "pirate_6";
    models[15] = "pirate_7";
    models[16] = "GenresBarrel2";
    models[17] = "pirate_8";
    models[18] = "BigPirate";
    models[19] = "corsair1_2";
    
    if(deck=="Deck_Near_Ship_Low"){
        mx = 10.0;
    }
    if(deck=="Deck_Near_Ship_Medium"){
        mx = 15.0;
    }
    if(deck=="Deck_Near_Ship_Big"){
        mx = 20.0;
    }
    if(deck=="My_Cabin_Medium"){
        mx = 15.0;
        models[0] = "GenresBag1";
        models[1] = "GenresBarrel1";
        models[2] = "GenresBottle1";
        models[3] = "GenresChest1";
        models[5] = "Isterling";
    }
    
    float crw = (mx/max)*cqt;

    int i;
    for (i=0; i < crw; i++){
        ch = GetCharacter(NPC_GenerateCharacter("Rand_"+i, models, "man", "man", 1, chr.nation, 1, false));
        SetFantomParamFromRank(ch, 1, true);
        ch.Dialog.Filename = "CabinCrew_dialog.c";
        ch.Dialog.currentnode = "go";
        LAi_warrior_DialogEnable(ch, true);
        PlaceCharacter(ch, "goto", chr.location);
    }
}<!--c2--></div><!--ec2-->

Now they are there. But my crewmembers wont talk with me :-/ Had i forgotten anything? I wrote the dialog-files and i think these are fine. Anyway, the crew is also not walking. How to write that? Tank you :)
 
<!--quoteo(post=328463:date=Jun 13 2009, 09:32 PM:name=Pieter Boelen)--><div class='quotetop'>QUOTE (Pieter Boelen @ Jun 13 2009, 09:32 PM) <a href="index.php?act=findpost&pid=328463"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Incorrect/no LAi type?<!--QuoteEnd--></div><!--QuoteEEnd-->

Yes! That was it! Thank you :-D
Now they are walking and talking and anything is fine <img src="style_emoticons/<#EMO_DIR#>/bow.gif" style="vertical-align:middle" emoid=":bow" border="0" alt="bow.gif" />
 
Congratulations, mate! <img src="style_emoticons/<#EMO_DIR#>/me.gif" style="vertical-align:middle" emoid=":onya" border="0" alt="me.gif" />
 
Back
Top