Jump to content

scripting help


LVB2

Recommended Posts

Hello all im new to modding im have trouble with scripting i cant figure out how a companion script or quest script should look or in other words the structure of them i have this so far and i dont know if its right

 

 

 

scn Amy06companionscript

 

Begin OnLoad

 

set playerteammate 1

 

;------------- wheel Variables -------------

short CombatStyleRanged

short CombatStyleMelee

short IsFollowingDefault

short IsFollowingLong

short FollowerSwitchAggressive ; 0 = Passive (wait for player), 1 = Aggressive (attack when see enemy)

short Waiting

 

 

but what else to put im also confused on can someone help me i read the g e c k tuturals but what i have read are about creating a vault or basic vault quest about exploring but nothing on companion scripts or how to create them . i made and npc but i dont know how script to be a companion or to make a quest to get my companion or just to put him in the game so he talk to u so u can hire them i really need help i would much appreciated thank you

Link to comment
Share on other sites

This is probably not what you want to hear, but I've combed through the forums for an answer to this myself (several people have had this difficulty, apparently). Everybody says to use pretty much the code you've given as an example and to set your NPC as a teammate, but those things alone will not connect the wheel correctly-- or at least, they haven't for me, and I've tried five or six times (NPCs based on vanilla followers as well as made from scratch). I've gone through about a half dozen companion mods looking for the answer, but I haven't found it yet. Sigh.

 

I wish you luck, though, and if you figure it out, would you please post it to the forums? :)

Link to comment
Share on other sites

yes if get any info i surly will put it on the forum i have tried to many of times different mods i recently made a companion from nccs companion system i have doenload the companion wheel but i cant get it to work i need help lol this to much like work
Link to comment
Share on other sites

drakeelvin has put together a follower template esp here:

 

http://www.newvegasnexus.com/downloads/file.php?id=43133

 

It has the wheel, packages, etc and is meant to be used by a more advanced modder that understands the fundamentals because you'd need to be able to navigate your way through the esp to know what to replace to make it your own. The idea is you change the things in this esp that make it the default follower so that it becomes your follower so you don't need to make your esp dependent on another one as a master. You might use the documentation he provides to see if you can figure out how things work rather than struggling to work from scratch with examples from varied sources. I remember trying to learn to do this stuff in the beginning and I think a template with documentation would have been a godsend.

 

@geekminxen -

 

The variables in the script alone and YourCompanionRef.setplayerteammate to 1 won't get your companion doing what you want. In addition to that, to see what you need to get done, you would need to look at the vNPCFollowers quest (if you were going to use the vanilla followers as an example) which is where all the vanilla followers basic wheel dialogue is and in the results scripts of that dialogue are the commands needed to make things happen.

 

So for instance for the trade segment of the wheel, in your trade dialogue topic, in the results script, you'd have to put

 

YourCompanionRef.OpenTeammateContainer

 

and then that will happen when the wheel is up and the trade part is activated.

 

The other part that needs to be done, say, for following, is that you need to copy what is in the results script, into your close distance following topic,

 

Set YourCompanionRef.IsFollowingDefault to 1
YourCompanionRef.evp

 

But you also have to create the follow package for the follower. And you need a package for waiting and long follow as well.

 

But the esp that drakeelvin has made has all those things and some scripting as well so I believe the only parts you have to do are the NPC creation, NPC placement in the world, changing the dialogue to suit you, and any other above and beyond the basics kinds of things.

 

:) llama

Link to comment
Share on other sites

@geekminxen -

 

<snip>

The other part that needs to be done, say, for following, is that you need to copy what is in the results script, into your close distance following topic,

 

Set YourCompanionRef.IsFollowingDefault to 1
YourCompanionRef.evp

 

But you also have to create the follow package for the follower. And you need a package for waiting and long follow as well.

 

<snip>

 

:) llama

 

Ah, llama, again you go above and beyond in your efforts to educate. :) Thing is, I did all those things- or at least, I tried. I must have typed in something wrong or missed a name change or something. I'm thinking about backtracking through my guy's mod like I'm making it from the very start so I can check the code line by line. If those are the things you do, and I've done them, I obviously dropped a ball somewhere.

 

And I will definitely check out drakeelvin's esp. I know there are mods that let you make companions, but then the companions have to run alongside that mod-- NCCS, for example. And maybe this is silly, but I didn't want to stand on someone else's shoulders-- I wanted my little esp to be mine. I want to know how to do all this stuff, and why it works, so I can reliably (or as reliably as I can do anything) do it again. But drakeelvin's esp sounds like it's more of a roadmap than someone else's base to build your own companion on. I will comb through it right now. Thank you. Again. As always. :D

 

(Oh, and I sent you a question about Audacity-- please ignore that. XD )

Link to comment
Share on other sites

Ah, llama, again you go above and beyond in your efforts to educate. :) Thing is, I did all those things- or at least, I tried. I must have typed in something wrong or missed a name change or something. I'm thinking about backtracking through my guy's mod like I'm making it from the very start so I can check the code line by line. If those are the things you do, and I've done them, I obviously dropped a ball somewhere.

 

Well, those are the minimum things I do and it should work for a basic companion that you've created from scratch. Sometimes getting things to work requires more, but for the basics, it shouldn't. And, you might not have dropped the ball. You can do everything "right" and something might not be working for some reason. The GECK can be extremely frustrating at times and can require great persistence to power through those times. The problem with that, is when you first start out, you don't always know the difference between when you've made a mistake and when you need to keep trying different approaches because what you've done is right but just not working this time/in this particular circumstance. If you run into something like that feel free to send me a PM, I might have an idea what the problem might be.

Link to comment
Share on other sites

The problem with that, is when you first start out, you don't always know the difference between when you've made a mistake and when you need to keep trying different approaches because what you've done is right but just not working this time/in this particular circumstance.

 

Well said. I don't know enough yet to know when I'm right and when I'm wrong. :)

 

If you run into something like that feel free to send me a PM, I might have an idea what the problem might be.

 

You're fantabulous. You can't kudo someone more than once, can you? :}

Link to comment
Share on other sites

You're the best, llama! I went back through all my code, tidying and double checking, and found my mistake. Now my problem child character follows, waits, and takes orders like a good boy. :)

 

LVB2, if you don't want to use the esp llama recommends, you can follow llama's advice about vNPCFollowers quest and get your wheel working. Hoo!

Link to comment
Share on other sites

thank you for reply i have download the amigo cafe im going to try that i deleted my companion from scatch i will start over it took me along time to get as far as i was but i was wanting to learn more to create vanilla companion from scratch and learn all the scripts and how to write tham the g e ck is very fustrating is there any other modding software out there to use thats better rhan the g e c k and its user friendly please help if cam u guys been very help thank you also i will look into the vNPCFollowers quest too Edited by LVB2
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...