.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening

Reply
 
Thread Tools Display Modes
  #1  
Old May 18th, 2012, 04:03 PM

Snacktime Snacktime is offline
Corporal
 
Join Date: Jun 2007
Location: Atlanta
Posts: 155
Thanks: 0
Thanked 1 Time in 1 Post
Snacktime is on a distinguished road
Default Quick scripting question

Is it possible to script a commander to cast a spell that you have not researched at the time you are scripting, but that you know you will have researched by the combat phase of the turn? Will it work?
Reply With Quote
  #2  
Old May 18th, 2012, 04:11 PM

Immaculate Immaculate is offline
Captain
 
Join Date: Sep 2009
Posts: 992
Thanks: 47
Thanked 23 Times in 19 Posts
Immaculate is on a distinguished road
Default Re: Quick scripting question

no- you cannot select a spell you have not researched. the best you can do is to script "cast spell" using the generic command and hope they go for the right one- in some cases it works.
Reply With Quote
  #3  
Old May 19th, 2012, 07:10 AM
Soyweiser's Avatar

Soyweiser Soyweiser is offline
Colonel
 
Join Date: Nov 2008
Posts: 1,735
Thanks: 272
Thanked 120 Times in 93 Posts
Soyweiser is on a distinguished road
Default Re: Quick scripting question

It depends on the spell if Immaculate's trick works. If it is a spell they would cast after the 5 rounds of scripting are over, then it will probably get cast. Otherwise, nope. (This means you can test if they will cast your spell).
__________________
I'm acting like a high school girl /\
Bookmark these links:
http://dom3.servegame.com/wiki/
http://wolfsbane.alwaysdata.net/Spells.html
Test stuff, use the debug mod:
http://forum.shrapnelgames.com/showthread.php?t=36453
Reply With Quote
  #4  
Old May 19th, 2012, 08:24 AM

Snacktime Snacktime is offline
Corporal
 
Join Date: Jun 2007
Location: Atlanta
Posts: 155
Thanks: 0
Thanked 1 Time in 1 Post
Snacktime is on a distinguished road
Default Re: Quick scripting question

Thanks guys!
Reply With Quote
  #5  
Old May 22nd, 2012, 06:18 PM

JonBrave JonBrave is offline
Second Lieutenant
 
Join Date: Aug 2010
Posts: 546
Thanks: 100
Thanked 10 Times in 8 Posts
JonBrave is on a distinguished road
Default Re: Quick scripting question

As I learnt recently, if you script to cast a spell and it can't be cast (e.g. insufficient level or gems, or already cast), the mage will "substitute" not "skip". So you could do that in the script and hope he will pick a newly discovered spell...
Reply With Quote
  #6  
Old May 22nd, 2012, 08:23 PM

krpeters krpeters is offline
Second Lieutenant
 
Join Date: Dec 2006
Posts: 564
Thanks: 1
Thanked 10 Times in 7 Posts
krpeters is on a distinguished road
Default Re: Quick scripting question

Keep in mind that "substitute" means "commit suicide" whenever possible.

For example, an Eagle King casting Ironskin on his own, then frying himself with Shock Wave.
Reply With Quote
The Following User Says Thank You to krpeters For This Useful Post:
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 03:26 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.