How to make a summon spell once a day and outside only?

Post » Thu Nov 11, 2010 8:14 am

I made a summon giant skeleton spell. Its a god ability so I want it to be once a day. Also its huge, so outside only is a must.
User avatar
DAVId MArtInez
 
Posts: 3410
Joined: Fri Aug 10, 2007 1:16 am

Post » Thu Nov 11, 2010 4:47 pm

Set it so it's a greater power (simply called a power in the cs). Greater powers can only be used once a day. I don't know your exact script, but to make it outside only, use this if statement, or something like it. all it does is terminate the script if the player is inside.

if player.IsInInterior == 1
return
endif
User avatar
Jake Easom
 
Posts: 3424
Joined: Sun Jul 29, 2007 4:33 am

Post » Thu Nov 11, 2010 6:09 pm

Okay so I went to powers under spells and tryed to make my spell but it kept adding it to spells instead of the powers tab.
And where would I insert that command?



ScriptName SummonSusanoSCR

;This script can be used as a template for custom summoned creatures/NPC's

float timer
float fade
short playonce
ref SUMN

Begin ScriptEffectStart

;Set temp reference for scripting.
;Allows faster transition of script as template. Also allows for leveled summon.
set SUMN to SummonSusano1REF
;Reset our creature if re-summoned before time runs out on spell
SUMN.disable

;Now we move our creature to the Player
;Move the creature reference to the worldspace of the Player
SUMN.moveto Player 30 30 10
;Make our creature visible and active
SUMN.enable
SUMN.Addspell AbGhostNPC

set fade to 1 ;Resets the alpha fade variable to 1

End

Begin ScriptEffectUpdate

if ( timer > 50 ) ;Creature is dead and fade timer passed
;Move our creature back to it's holding cell
SUMN.kill
SUMN.moveto CreatureCageREF 0 0 10
;Reset our creature if dead
SUMN.resurrect
;Set our creature to an unprocessed state
SUMN.disable
endif

;Adjust timer state for early fade/disable upon death
if ( SUMN.getdead == 1 ) && ( timer < 50 )
set timer to 100
endif

if ( timer > 0.1 ) && ( playonce == 0 )
;Play effect for creature entrance
set playonce to 1
endif


;Increment timer
set timer to timer + GetSecondsPassed


if ( timer > 50 ) && ( playonce == 1 )
;Play effect for creature exit/death
SUMN.kill
set playonce to 2
endif

if ( playonce == 2 )
;Fade creature for exit/death
set fade to fade - 0.03
SUMN.saa fade
endif


End

Begin ScriptEffectFinish

;Move our creature back to it's holding cell
SUMN.moveto CreatureCageREF 0 0 10
;Reset our creature if dead
SUMN.resurrect
;Set our creature to an unprocessed state
SUMN.disable

End
User avatar
Mr. Ray
 
Posts: 3459
Joined: Sun Jul 29, 2007 8:08 am

Post » Thu Nov 11, 2010 5:32 am

Okay so I went to powers under spells and tryed to make my spell but it kept adding it to spells instead of the powers tab.
And where would I insert that command?



Put the command right after Begin ScriptEffectStart. You could also put a message in saying that you can't use this spell while inside. That part would look like:

Begin ScriptEffectStartif player.IsInInterior == 1Message "You can't use this while indoors."returnendif


Note: This will also prevent the spell from being used in the Arena, since the game considers that to be an interior cell.

As for making the spell a Greater Power, open you spell in the CS. On the left side of the Spell window, you will see 3 data fields: ID, Name and Type. Click on Type and select Power from the dropdown menu. That will turn you spell into a Greater Power.

Note: NPCs cannot sell Greater Power spells, so you won't be able to buy this from a merchant unless you put it in a http://cs.elderscrolls.com/constwiki/index.php/Scripting_Tutorial:_Spell_Tome.
User avatar
Jennifer Rose
 
Posts: 3432
Joined: Wed Jan 17, 2007 2:54 pm

Post » Thu Nov 11, 2010 1:52 pm

Thanks working on it right now lol
User avatar
Rhi Edwards
 
Posts: 3453
Joined: Fri Jul 28, 2006 1:42 am

Post » Thu Nov 11, 2010 7:40 pm

Wait I have made my spell tome but the tutorial wants me to add it via command. How can I place it somewhere in the game instead of getting it via a command?
User avatar
Donald Richards
 
Posts: 3378
Joined: Sat Jun 30, 2007 3:59 am

Post » Thu Nov 11, 2010 7:54 am

Wait I have made my spell tome but the tutorial wants me to add it via command. How can I place it somewhere in the game instead of getting it via a command?

If it's a Greater Power, a merchant can't sell it to you, so you'll need an alternative. You could create your own Doomstone that adds it to you via script. The script would look something like:

scn SusanoSpellAdScriptshort DoOnceBegin OnActivate Player  If DoOnce == 0    Player.addspell SpellIDHere    Set DoOnce to 1  Elseif DoOnce == 1    Message "You have already gained the power of this stone."  Endifend


Or you could add it via http://cs.elderscrolls.com/constwiki/index.php/Scripting_Tutorial:_Spell_Tome
User avatar
casey macmillan
 
Posts: 3474
Joined: Fri Feb 09, 2007 7:37 pm

Post » Thu Nov 11, 2010 5:03 am

I figured that out already. Now Im working on figureing out how to merge mods because the mod I just made depends on another but wont work when its acutally in game. Im using a race from another mod in the one I made and it wont show the persons head. I guess I have to merge them somehow.
User avatar
Laura Shipley
 
Posts: 3564
Joined: Thu Oct 26, 2006 4:47 am

Post » Thu Nov 11, 2010 12:44 pm

I figured that out already.


Awesome! :goodjob: You're getting the hang of the CS quite well.

Now Im working on figureing out how to merge mods because the mod I just made depends on another but wont work when its acutally in game. Im using a race from another mod in the one I made and it wont show the persons head. I guess I have to merge them somehow.


http://tesnexus.com/downloads/file.php?id=8665 has a 'Merge Plugins' option that should work for you.

Also check out http://cs.elderscrolls.com/constwiki/index.php/De-Isolation_Tutorial
User avatar
KiiSsez jdgaf Benzler
 
Posts: 3546
Joined: Fri Mar 16, 2007 7:10 am

Post » Thu Nov 11, 2010 7:29 am

This mod Im depending on has meshes textures and race folders so im not sure. Should I merge them or make the mod an esm file? I tryed merging them but nothing happened.
User avatar
Sweets Sweets
 
Posts: 3339
Joined: Tue Jun 13, 2006 3:26 am

Post » Thu Nov 11, 2010 7:32 am

So I made the mod a master file and it worked but it also requires for the esp to still be selected in the data files. Now how can I upload this? Will I have to upload the other persons mod as an esm also?
User avatar
Elina
 
Posts: 3411
Joined: Wed Jun 21, 2006 10:09 pm

Post » Thu Nov 11, 2010 6:07 am

I might be a bit late with this, but since the spell failing when indoors is part of the effect, doesn't that mean the greater power is used up regardless of whether it works?
User avatar
Rach B
 
Posts: 3419
Joined: Thu Mar 08, 2007 11:30 am


Return to IV - Oblivion