Hey guys, reaaaaally newbie this one.
What should I do to make a script run an action? I've tried to inser the action comand line at my script, but I'm receiving an unkow state in compiler error. I think I need to associate the action with its object, but I dont know how.
Bellow goes my script.
Cheers
void main(){
object oPC = GetEnteringObject();
if (!GetIsPC(oPC)) return;
SetCutsceneMode(oPC, TRUE);
SetCameraMode(oPC, CAMERA_MODE_CHASE_CAMERA);actionActionMoveToObject(rei, FALSE, fRange=1.0f);
}
Newbie question regarding actions scripting
Débuté par
el.sombrero
, nov. 01 2012 07:48
#1
Posté 01 novembre 2012 - 07:48
#2
Posté 01 novembre 2012 - 07:51
Check out: AssignCommand
#3
Posté 01 novembre 2012 - 11:03
SetCameraMode(oPC, CAMERA_MODE_CHASE_CAMERA);actionActionMoveToObject(rei, FALSE, fRange=1.0f);
should be
SetCameraMode(oPC, CAMERA_MODE_CHASE_CAMERA);
AssignCommand(oPC, ActionMoveToObject(rei, FALSE));
and you need to define the object 'rei' somehow:
object rei = GetNearestObjectByTag("rei");
should be
SetCameraMode(oPC, CAMERA_MODE_CHASE_CAMERA);
AssignCommand(oPC, ActionMoveToObject(rei, FALSE));
and you need to define the object 'rei' somehow:
object rei = GetNearestObjectByTag("rei");
#4
Posté 12 novembre 2012 - 01:18
Red Stripes and Marshall... thx! problem solved!
by the way. I'm trying to change the mood state of some npc (need them to cheer, clap hands or something like that)... but didint find anything like that at their "behavior" properties. Any tip?
by the way. I'm trying to change the mood state of some npc (need them to cheer, clap hands or something like that)... but didint find anything like that at their "behavior" properties. Any tip?
#5
Posté 12 novembre 2012 - 01:50
You can set them to play certain animations, or play their voice emotes, but if you want to just set a "mood" property, then you'd have to build a little system around that.
List of "voice chat" emotes, using the PlayVoiceChat command:
http://nwn.wikia.com/wiki/VOICE_CHAT_*
Also, a list of the animations you can select to play using the PlayCustomAnimation command:
http://nwn2.wikia.co...t_of_animations
List of "voice chat" emotes, using the PlayVoiceChat command:
http://nwn.wikia.com/wiki/VOICE_CHAT_*
Also, a list of the animations you can select to play using the PlayCustomAnimation command:
http://nwn2.wikia.co...t_of_animations
Modifié par Tchos, 12 novembre 2012 - 01:51 .





Retour en haut







