logo logo

 Back to main page

The NWNX Community Forum

 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
NWNX Letoscript - modifying PCs
Goto page Previous  1, 2, 3
 
Post new topic   Reply to topic    nwnx.org Forum Index -> Windows technical support
View previous topic :: View next topic  
Author Message
xardex



Joined: 02 Mar 2010
Posts: 40

PostPosted: Sun Mar 07, 2010 0:11    Post subject: Reply with quote



It works now! Very Happy

Thanks alot for your help MaxRock, Terra, Shado0ow... and everyone else whose name I dont remember right now!

Btw, I figured out how to remove all feats and modify HP. (!) Wink
Back to top
View user's profile Send private message
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Sun Apr 18, 2010 20:52    Post subject: Reply with quote

Terra_777 wrote:
Oh, yeah.

Code:
AssignCommand( GetModule(), Leto_ExecuteFileWritingOperation( ... ) );


If it runs on the PC it won't work since the PC is booted.


I'm having a very similar problem, I've done everything specified in the topic so far, but where do I put:
Code:

AssignCommand( GetModule(), Leto_ExecuteFileWritingOperation(oPC, sScript) );

?

So far, my script looks like this:
Code:

#include "inc_letowrapperj"
void main()
{
object oPC = GetLastUsedBy();

if (!GetIsPC(oPC)) return;
if (GetItemPossessedBy(oPC, "godlypresence")!= OBJECT_INVALID)
   {
   FloatingTextStringOnCreature("You can't worship two gods!", oPC);
   return;
   }
else
   {
   CreateItemOnObject("godlypresence", oPC);
   string sScript = Leto_GenerateLetoScriptModifyAbility(ABILITY_DEXTERITY, 2);
   sScript += Leto_GenerateLetoScriptModifyAbility(ABILITY_CHARISMA, 2);
   FloatingTextStringOnCreature("Applying ability bonuses.", oPC);
   AssignCommand( GetModule(), Leto_ExecuteFileWritingOperation(oPC, sScript) );
}
}


I'm trying to make it so that this gives u 2 dex and 2 cha and then it creates an item with the resref: godlypresence, then it boots u, and if u have the item godlypresence already, then it says "You can't worship two gods!"

the problem is, it wont give me my ability bonuses, the rest works though.

thx in advance,

Tenshar
Back to top
View user's profile Send private message
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Mon Apr 19, 2010 18:53    Post subject: Reply with quote

bump?
Back to top
View user's profile Send private message
Terra_777



Joined: 27 Jun 2008
Posts: 216
Location: Sweden

PostPosted: Tue Apr 20, 2010 0:47    Post subject: Reply with quote

plugin: http://www.nwnx.org/phpBB2/viewtopic.php?t=1535

Code:
#include "nwnx_funcs"
void main( ){

    object oPC = GetLastUsedBy( );

    if( !GetIsPC( oPC ) ){

        return;
    }
    else if( GetItemPossessedBy( oPC, "godlypresence" ) != OBJECT_INVALID ){

        FloatingTextStringOnCreature( "You can't worship two gods!", oPC );
    }

    else{

        CreateItemOnObject( "godlypresence", oPC );
        FloatingTextStringOnCreature( "Applying ability bonuses.", oPC );
        NWNXFuncs_ModAbilityScore( oPC, ABILITY_CHARISMA, 2 );
        NWNXFuncs_ModAbilityScore( oPC, ABILITY_DEXTERITY, 2 );
    }
}


Cool
_________________
I dun have any signature, I'm happy anyway.
Back to top
View user's profile Send private message Send e-mail MSN Messenger
ShaDoOoW



Joined: 20 Aug 2005
Posts: 584

PostPosted: Tue Apr 20, 2010 0:54    Post subject: Reply with quote

Yeah, screw letoscript Very Happy.
_________________
Community Patch / NWNX Patch / NWNX Files / NWNX Connect
Back to top
View user's profile Send private message
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Tue Apr 20, 2010 9:32    Post subject: Reply with quote

Hm, didn't work, I used nwnx to test it, it booted me when I used the item, I logged back on and no changes made Sad
any ideas?

- Tenshar
Back to top
View user's profile Send private message
Terra_777



Joined: 27 Jun 2008
Posts: 216
Location: Sweden

PostPosted: Tue Apr 20, 2010 11:19    Post subject: Reply with quote

the above script is for a memoryediting plugin so you don't need to be booted.

Chances are that when you got booted the changes made didnt get saved.
_________________
I dun have any signature, I'm happy anyway.
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Tue Apr 20, 2010 21:14    Post subject: Reply with quote

hm, and how do I remove booting the player?
Back to top
View user's profile Send private message
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Sat Apr 24, 2010 22:26    Post subject: Reply with quote

*cough*bump!*cough* Very Happy
Back to top
View user's profile Send private message
Lokey



Joined: 02 Jan 2005
Posts: 158

PostPosted: Sun Apr 25, 2010 11:41    Post subject: Reply with quote

In linux you have a few more options for mods without kicking player off server. In win, see terra's posts.
_________________
Neversummer PW NWNx powered mayhem Wink
Back to top
View user's profile Send private message
Tenshar



Joined: 18 Apr 2010
Posts: 13

PostPosted: Wed Apr 28, 2010 9:23    Post subject: Reply with quote

Yea, I'm using his script, It boots me though Sad
Back to top
View user's profile Send private message
Terra_777



Joined: 27 Jun 2008
Posts: 216
Location: Sweden

PostPosted: Wed Apr 28, 2010 13:19    Post subject: Reply with quote

Install this: http://www.nwnx.org/phpBB2/viewtopic.php?t=1535

Then replace this;

Code:
#include "inc_letowrapperj"
void main()
{
object oPC = GetLastUsedBy();

if (!GetIsPC(oPC)) return;
if (GetItemPossessedBy(oPC, "godlypresence")!= OBJECT_INVALID)
   {
   FloatingTextStringOnCreature("You can't worship two gods!", oPC);
   return;
   }
else
   {
   CreateItemOnObject("godlypresence", oPC);
   string sScript = Leto_GenerateLetoScriptModifyAbility(ABILITY_DEXTERITY, 2);
   sScript += Leto_GenerateLetoScriptModifyAbility(ABILITY_CHARISMA, 2);
   FloatingTextStringOnCreature("Applying ability bonuses.", oPC);
   AssignCommand( GetModule(), Leto_ExecuteFileWritingOperation(oPC, sScript) );
}
}


With this:

Code:
#include "nwnx_funcs"
void main( ){

    object oPC = GetLastUsedBy( );

    if( !GetIsPC( oPC ) ){

        return;
    }
    else if( GetItemPossessedBy( oPC, "godlypresence" ) != OBJECT_INVALID ){

        FloatingTextStringOnCreature( "You can't worship two gods!", oPC );
    }

    else{

        CreateItemOnObject( "godlypresence", oPC );
        FloatingTextStringOnCreature( "Applying ability bonuses.", oPC );
        NWNXFuncs_ModAbilityScore( oPC, ABILITY_CHARISMA, 2 );
        NWNXFuncs_ModAbilityScore( oPC, ABILITY_DEXTERITY, 2 );
    }
}


If you still get booted its not the leto-stuff unless you got it someplace more. Smile
_________________
I dun have any signature, I'm happy anyway.
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Paco's Revenge



Joined: 24 Jan 2009
Posts: 7

PostPosted: Thu Aug 12, 2010 0:25    Post subject: Reply with quote

Quick question...where can I download leto 3.24 rather than 3.26? I found 3.25 but no 3.24?

Also if anyone is bored and wants to show me how to make the Letoscript work I will gladly give you carte blanche and free reign to our host computer through VNC.
Back to top
View user's profile Send private message
Fireboar



Joined: 17 Feb 2008
Posts: 323

PostPosted: Thu Aug 12, 2010 14:33    Post subject: Reply with quote

Paco's Revenge wrote:
Also if anyone is bored and wants to show me how to make the Letoscript work I will gladly give you carte blanche and free reign to our host computer through VNC.


Don't make offers like that publicly, ever. It's quite bad for you.

As for your question, you can get 3+24 from Sourceforge
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    nwnx.org Forum Index -> Windows technical support All times are GMT + 2 Hours
Goto page Previous  1, 2, 3
Page 3 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group