Neverwinter Nights > NwN Building

Random Script

(1/2) > >>

Xen:
Ok, I know people are gonna request scripts, Or some are embarrased to. I'll make some scripts and just post em. Do not add comments this is not for that. Just scripts if You want to add comments add it at the base of your post AFTER your script.

Xen:
//Basic Sit Script (Place OnUsed in an objects "Events" tab)[/span]
[span style=\'color:blue\']void[/span] main()
{
[span style=\'color:blue\']object[/span] oObject = [span style=\'color:blue\']OBJECT_SELF[/span];
[span style=\'color:blue\']object[/span] oUser = GetLatsUsedBy();

AssignCommand(oUser, ActionSit(oObject));
}

[span style=\'color:red\']Heres the basic sit script everyone keeps wanting.

Xen:
/*
Basic Conversation starter, You can use it werever you want. Lets say you put it OnUsed in a objects "Events" tag it will fire every tim ethat object is used
*/
[/span][span style=\'color:blue\']void[/span] StartConversation([span style=\'color:blue\']object[/span] oPC)
{
AssignCommand(oPC, ActionStartConversation(PC, "convo resref", [span style=\'color:blue\']TRUE[/span]));
}



[span style=\'color:red\']//Now, the command:[/span]

[span style=\'color:blue\']void[/span] main()
{
[span style=\'color:green\']// In this isntance we are going to use "OnUsed"[/span]
[span style=\'color:blue\']object oUser = GetLastUsedBy();
StartConversation(oUser);
}

Xen:
/*
Simple Animation que for placable objects, In this example we are making a Statue that Causes you to worship:
*/[/span]
[span style=\'color:blue\']void[/span] main()
{
[span style=\'color:blue\']object oUser = GetLastUsedBy();

AssignCommand(oUser, ActionPlayAnimation(ANIMATION_LOOPING_WORSHIP,5.0);
}

420:
//Alternate script for an items OnUsed trigger event, will automatically use the conversation that is specified in the "conversation" field in an objects advanced menu

void main()
{
    object oPC = GetLastUsedBy();
    ActionStartConversation(oPC, "", TRUE, FALSE);
}


(The conversation started is private so as not to bug other players.)

-420

Navigation

[0] Message Index

[#] Next page

Go to full version