Jump to content

[Scripting & Mapping] Background NPCs


Recommended Posts

Posted

Hey, everyone!

 

I've a few questions but some context always helps, so let me explain what I want to create! For the the single player level I am currently working on, I would like the player to have the option to spar with up to five other students positioned around the arena. While you're not sparring, I'd like for two random NPCs to put on a display of swordsmanship.

 

I made two friendly NPCs and gave them a command to attack one another, and they obeyed. But without any more specific directions, it turned into the pair of them just kicking each other over constantly. They would also have a tendency to wander into one corner of the arena and stay there, or drift apart to the point they just looked at one another. I assume waypoints are a key thing here, but I don't completely understand how they work, so some advice in that area would be helpful.

 

The second problem I'm having is with a pair of students who I simply wanted to behave as if they were talking to one another, moving through the different talk animations one after the other. I've done a lot of edits to that script, but the most recent one is below:

 

 

lsHCwfh.jpg

 

 

Every time I update this, something different happens. Most recently, one just wound up jogging on the spot, which'd look great if I was planning to put Wii Fit on a tele infront of her of course, but that might be a tad inappropriate for the setting!

 

Another question down the line is going to be about how to appropriately spawn all of the characters around the map. For instance, Luke is in the main hall. I could set him to spawn when the door is triggered and then despawn the next time, but then you could trick it. Correct me if I'm wrong, but the "if" statement would be the appropriate thing to use here? If anyone with the capacity to help me out could drop a line here, it would be greatly appreciated!

 

EDIT: One of course realises AFTER creating his topic that there is, of course, a forum marked as "Coding & Scripting" so if you feel obliged to relocate this, I'll understand!

Posted

Could you perhaps replicate the script code from the Yavin Temple map in Outcast for the students?

MB2 Beta Tester / MB2 FA Assistant Dev

Posted

Could you perhaps replicate the script code from the Yavin Temple map in Outcast for the students?

I only have the Jedi Academy scripts to use as references. For conversation, I was looking at t1_inter in particular, which is how I came up with the example above. As for the sparring students, I'm just going to be browsing through tutorials in the mean time!  :o

Posted

I only have the Jedi Academy scripts to use as references. For conversation, I was looking at t1_inter in particular, which is how I came up with the example above. As for the sparring students, I'm just going to be browsing through tutorials in the mean time!  :o

 

I don't mind sending you a copy of the map + script if you want.

MB2 Beta Tester / MB2 FA Assistant Dev

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...