Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Warp scripting, help needed.

Page: 1 of 1
 Mav
08-04-2004, 2:25 AM
#1
I was just wondering if a script could be made to warp the PC to a specific part of a module by using the X, Y, Z coordinates that you can get using the whereami cheat? Thanks in Advance.

Mav
 Darth333
08-04-2004, 10:40 AM
#2
You should find everything you need here: http://www.lucasforums.com/showthread.php?s=&threadid=132045) :)
 Mav
08-04-2004, 9:14 PM
#3
Thanks a bunch Darth333 I had a feeling that you would be the first one to help, and I think I am going to use the script that you made that uses the way point, thanks again.
 Darth333
08-04-2004, 10:21 PM
#4
Glad I could help :)
 Mav
08-05-2004, 1:32 AM
#5
If I ever get this finished, what with school and all I'll be sure you are the first to give it a BETA test beofre the release ;), oh and I might have more scripting questions, but I'll just post in this thread if I do, Thanks Again.

Mav
 Mav
08-05-2004, 3:21 AM
#6
Okay so I've seen the script that is used to spawn a NPC at a given point, but what I need is a script to spawn 3 NPCs at a given point, help anyone or I could just attach three of the spawn scripts to the dialogue instead, but I figure that a script that would spawn 3 NPCs would be easier, help anyone???

you'll get a cookie
 RedHawke
08-05-2004, 3:35 AM
#7
^^^^
Mav, if you are spawning 3 NPC's you will need a seperate spawn point for each one (Each one is simply gotten with a whereami cheat), and then the code would look like this;


void main()
{
float a=0.00f; //X Cordinate 1
float b=0.00f; //Y Cordinate 1
float c=0.00f; //Z Cordinate 1
float d=0.0f; // NPC Facing 1
vector vecNPC1=Vector(a,b,c);
location locNPC1=Location(vecNPC1, d);
object oNPC1=CreateObject(OBJECT_TYPE_CREATURE,"npc_taghere",locNPC1);
float e=0.00f; //X Cordinate 2
float f=0.00f; //Y Cordinate 2
float g=0.00f; //Z Cordinate 2
float h=0.0f; // NPC Facing 2
vector vecNPC2=Vector(e,f,g);
location locNPC2=Location(vecNPC2, h);
object oNPC2=CreateObject(OBJECT_TYPE_CREATURE,"npc_taghere",locNPC2);
float i=0.00f; //X Cordinate 3
float j=0.00f; //Y Cordinate 3
float k=0.00f; //Z Cordinate 3
float l=0.0f; // NPC Facing 3
vector vecNPC3=Vector(i,j,k);
location locNPC3=Location(vecNPC3, l);
object oNPC3=CreateObject(OBJECT_TYPE_CREATURE,"npc_taghere",locNPC3);
}


You can keep adding sections of the code to spawn more NPC's. Just be sure to keep the numbering conventions going with vecNPC, and locNPC, as well as the four floats for each NPC location.

I hope this helps! :D
 Mav
08-05-2004, 4:28 AM
#8
Thanks once again RedHawke, thanks to you and Darth333, with an all nighter and an heavy session of testing/work tommorrow my newest module may be out sooner than even I imagined hopefully by Sunday, I thought it would take a month...or two. Oh and as promised here is your cookie:

MMMmmmmMMMmmmm (http://home.cwru.edu/~bxl34/photos/cookie-1152x864.jpg)

Edit: Oh and I was one step ahead of you RedHawke I already have my three locations for the NPCs, I'll let you and Darth333 BETA test it before final release....if I have the time
 Mav
08-05-2004, 5:09 AM
#9
First of all the script works great and everybody spawns and everyon eis happy YEAAHHAHHAHHA..... okay it's late and I'm getting delusional, okay I don't want to spoil anything, but although I have made sure that certain NPCs have lightsabers in there equipped item list, when you go to fight them they don't use lightsabers they decide to fight you with their fists any idea as to why??
 RedHawke
08-05-2004, 8:43 AM
#10
^^^^
Fighting with their fists huh?

Kung-Fu Sith! :D

That sounds like you need to check the combat script settings in the .utc files for the spawned NPC's, for simplicity you should clone the scripts used by other dark jedi in the game.
 Darth333
08-05-2004, 9:54 AM
#11
You can also attach a script to dialog to make them florish their sabers. Unfortunately i don't have nwscript with me right now to get the proper syntax and functions so try using Redhawke's method.
 Mav
08-05-2004, 4:46 PM
#12
Thanks for the help both of you, I think that you two should send me a PM with your e-mail so I can send you the BETA version of my new "module" so you can test it, well at least Darth333, I already have RedHawke's e-mail.
 Darth333
08-05-2004, 4:54 PM
#13
Check you pms :)
 Mav
08-05-2004, 6:10 PM
#14
Got it and I sent you the BETA version let me know what you think a.s.a.p. because after Saturday I wont be able to work on it. Heck I wont even be near a computer for two weeks after Saturday.
Page: 1 of 1