Jump to content

Vampire Disease Script


robotaz

Recommended Posts

Hey i'm not that great at writing scripts...But I was wondering if it was possible to write a script that when placed on a note can infect a player with the vampire disease. I'm making a mods that includes a full on vampire theme. So to enter the cave home you must click on a letter, a message box appears telling you the guidelines(tells you that you must be a vampire to enter) then it asks if you agree to these terms...Yes makes you a vampire if your not, and no inflicts damage upon you and tells you to be gone.

 

Is it possible to write a script like this? Is there already a script in the game that I can add to my messagebox script? Also is there anyway someone could maybe write one for me?

(Like I said I don't know much about scripting.)

 

Thanks!

 

EDIT: Also the script needs to add a key to the player if they answer the question yes

Edited by robotaz
Link to comment
Share on other sites

it is very much possible to do this

 

my suggestion to you, for the vampire script, is to open the CS, open the script window, click on open, and type V

the 3rd option should be VampireScript

this is the script that works the entire vampire system (the aging, becoming a vampire and all that)

so you could probably find all the lines you need there

 

as for adding a key, you can easily use the AddItem command

just make sure to use the ID of the key, and not the console command (meaning not the xx000xxxx code, the set ID for the item, that doesn't depend on the mods' place in the load order)

Link to comment
Share on other sites

Theres also a test script (used in that one room with the guy named "Vamp Chow") that turns you into a 100% Vampire, the one where you haven't drinken any blood for a while, and another that adds Porphyric Hemophilia.

 

I'm taking a guess at the cell name, but it might be TestVampire.

Edited by Guest
Link to comment
Share on other sites

So all these lines look important for being a vampire....Should I just add this to my current message box script?(also like I said I don't have much knowledge of scripting im a total noob)

 

Heres my current script....

 

Short controlvar

Short button

 

Begin OnActivate

If ( controlvar ==0 )

MessageBox "Welcome to my lair, you have been chosen by me to become the next vampire of our blood-line. To enter my home you must first be a vampire. To you agree to these conditions?", "Yes", "No"

Set controlvar to 1

ElseIf ( controlvar > 1)

Activate

Endif

End

 

Begin GameMode

If ( controlvar == 1 )

Set button to GetButtonPressed

If ( button == -1 )

Return

ElseIf ( button == 0)

MessageBox "Then welcome brother."

Player.additem VampiresLairKey 1

Set controlvar to 2

Else

MessageBox "Then Begone!"

Cast greatersucklifeforce Player

Set controlvar to 0

EndIf

ElseIf ( controlvar == 2 )

Activate

Set controlvar to 3

EndIf

End

 

 

Heres the script you told me to use....

 

ScriptName VampireTestScript

 

 

short doonce

 

Begin OnActivate

 

if isActionRef player == 1

 

if ( doonce == 0 )

player.addspell VampDisease

MessageBox "The process has begun. Wait three days, then take a nap. Enjoy!"

set doonce to 1

endif

 

endif

 

End

 

 

 

 

How would I combine these?

Link to comment
Share on other sites

i think that if you add

player.addspell VampDisease
after
MessageBox "Then welcome brother."
, it should make you a vampire

of course, the addspell only starts the disease, and not actually making you a vampire

but if you change your vampirism to 25, maybe the change will happen at once (but i really have no idea)

 

would it be horrible if you have to wait 3 days to use this??

because if not, then it should work well

 

on another note, i would like to make a suggestion (if i may)

perhaps you could make it a bit better, in terms of role playing, if you make it a bit more advanced than just "you want to become a vampire?? well, now you are"

i mean, maybe if you add some sort of a potion or something that the character has to drink

the thing is, it doesn't have to be an action or anything

you could just write it, just like you wrote the question if you would like to become a vampire

just my two cents, as it would probably make it much better (and make more sense) if you plan on releasing this mod

Link to comment
Share on other sites

scn robatazscript

short doonce
short controlvar
short button


Begin OnActivate

if isActionRef player == 1 && controlvar == 0
	MessageBox "Welcome to my lair, you have been chosen by me to become the next vampire of our blood-line. To enter my home you must first be a vampire. Do you agree to these conditions?", "Yes", "No"
		Set controlvar to 1
ElseIf ( controlvar > 1)
	Activate
Endif
end
Begin GameMode
If ( controlvar == 1 )
	Set button to GetButtonPressed
If ( button == -1 )
	Return
ElseIf ( button == 0)
	MessageBox "Then welcome brother." 
	Player.additem testkey 1
	player.addspell Vampirism100
	player.addspell Vampirism100Att
	player.addspell Vampirism100skills
	player.addspell VampireEmbraceofShadows
	player.addspell VampireSeduction
	player.addspell VampireReignofTerror
	player.addspell VampireHuntersSight
	set PCVampire to 4
endif
	Set controlvar to 2
Else
	MessageBox "Then Begone!"
Cast MG05ShockSpell20 Player
	Set controlvar to 0
EndIf
	ElseIf ( controlvar == 2 )
Activate
	Set controlvar to 3
EndIf
End

 

You could use that for your script. I did change the spell and key id in the script to make sure it would save, and it did, so it will work if it's what you want. I wasn't too sure though.

 

edit

 

You can delete the short doonce, I deleted it from the script when I was using it lol

Edited by Guest
Link to comment
Share on other sites

Ok....Well as soom as I enter the cell with the note that has the script on it, it immediatly says "Then Begone!"

 

Heres the current script...

 

 

scn VampiresNoteSCRIPT

 

Short controlvar

Short button

 

Begin OnActivate

If ( controlvar ==0 )

MessageBox "Welcome to my lair, you have been chosen by me to become the next vampire of our blood-line. To enter my home you must first be a vampire. To you agree to these conditions?", "Yes", ""No

Set controlvar to 1

ElseIf ( controlvar > 1)

Activate

Endif

End

 

Begin GameMode

If ( controlvar == 1 )

Set button to GetButtonPressed

If ( button == -1 )

Return

ElseIf ( button == 0)

MessageBox "Then welcome brother."

Player.addspell VampDisease

Player.additem VampiresLairKey 1

endif

Set controlvar to 3

Else

MessageBox "Then Begone!"

Cast greatersucklifeforce Player

Set controlvar to -1

EndIf

ElseIf ( controlvar == 2 )

Activate

Set controlvar to 3

EndIf

End

 

 

I think that there might be an error within my controlvar variables I got a little confused when I was putting them in

Edited by robotaz
Link to comment
Share on other sites

  • Recently Browsing   0 members

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