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

This Month's Specials

Air Command 3.0- Save $12.00
War Plan Pacific- Save $7.00

   







Go Back   .com.unity Forums > Shrapnel Community > Space Empires: IV & V > SEV Modders Knowledge Base

Reply
 
Thread Tools Display Modes
  #1  
Old October 14th, 2006, 01:17 AM
Captain Kwok's Avatar

Captain Kwok Captain Kwok is offline
National Security Advisor
 
Join Date: Oct 2001
Location: Toronto, Canada
Posts: 5,624
Thanks: 1
Thanked 14 Times in 12 Posts
Captain Kwok is on a distinguished road
Default Re: Modding SEV Thread Questions

It specifies a range of damage for the weapon. For example if the min is 30 and the max is 40, the weapons will do between 30-40 damage.
__________________
Space Empires Depot | SE:V Balance Mod
Reply With Quote
  #2  
Old October 14th, 2006, 01:22 AM
President_Elect_Shang's Avatar

President_Elect_Shang President_Elect_Shang is offline
Brigadier General
 
Join Date: Nov 2001
Location: WA
Posts: 1,894
Thanks: 5
Thanked 3 Times in 3 Posts
President_Elect_Shang is on a distinguished road
Default Re: Modding SEV Thread Questions

Perfect thanks; is there a utility or aid of some sort to help calculate the formula for the Hit Modifier?
__________________
President Elect Shang; Tal-Re Republic of Free Worlds
Welcome to Super Vegeta’s Big Bang Attack… Welcome to OBLIVION!
“Don Panoz made an awesome car and… an incinerator” Bill Auberlen
Reply With Quote
  #3  
Old October 14th, 2006, 01:35 AM
President_Elect_Shang's Avatar

President_Elect_Shang President_Elect_Shang is offline
Brigadier General
 
Join Date: Nov 2001
Location: WA
Posts: 1,894
Thanks: 5
Thanked 3 Times in 3 Posts
President_Elect_Shang is on a distinguished road
Default Re: Modding SEV Thread Questions

Wait no; I just don’t get that line. What is it doing? I read the description earlier but it makes no sense. For example:

0 – ([%Range%] * .5)

Is this saying that at range 50 I lose x accuracy? What value is x and how can I change it?

Can I make a weapon that will have the following hit probability?

Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 90 – 90 – 90 – 80 – 80 – 80 – 70 – 60 – 50 – 30 – 10
__________________
President Elect Shang; Tal-Re Republic of Free Worlds
Welcome to Super Vegeta’s Big Bang Attack… Welcome to OBLIVION!
“Don Panoz made an awesome car and… an incinerator” Bill Auberlen
Reply With Quote
  #4  
Old October 14th, 2006, 01:45 AM

Phoenix-D Phoenix-D is offline
National Security Advisor
 
Join Date: Nov 2000
Posts: 5,085
Thanks: 0
Thanked 0 Times in 0 Posts
Phoenix-D is on a distinguished road
Default Re: Modding SEV Thread Questions

That line is sayng that you'll lose 0.5% of accuracy per LS of distance. So at 50 LS you'll have a -25% modifier. You change the X by changing .5 to something else, or inputing a different forumla.

Doing that line won't be easy and it won't be short- you'll need lots of tested ifs.
__________________
Phoenix-D

I am not senile. I just talk to myself because the rest of you don't provide adequate conversation.
-Digger
Reply With Quote
  #5  
Old October 14th, 2006, 02:18 AM

Phoenix-D Phoenix-D is offline
National Security Advisor
 
Join Date: Nov 2000
Posts: 5,085
Thanks: 0
Thanked 0 Times in 0 Posts
Phoenix-D is on a distinguished road
Default Re: Modding SEV Thread Questions

The final forumla, or one way of doing it, looks like this:
0 - iif([%Range%] < 30, 10, iif([%Range%] < 60, 20, iif([%Range%] < 80, (30 + ([%Range%] - 60)), (50 + (([%Range%] - 80) * 2)))))

Just a bit messy. Most forumlas will not be anywhere NEAR this complicated, you just happened to pick a difficult one to do.

Here's the breakdown..
Code:

0 -
iif([%Range%] < 30, 10,
iif([%Range%] < 60, 20,
iif([%Range%] < 80, (30 + ([%Range%] - 60)),
(50 + (([%Range%] - 80) * 2)))))



First, a little note: %RANGE% is a variable- it is whatever the current range to the target is. If he's at 50ls its 50, if he's at 10ls its 10, 5 at 5ls, etc.

First line: 0 is just there to make the rest of the numbers negative by using the following - sign. The base to-hit in SE5 is 100%, so what this means is "100% - the result of the following formula" (call that X).

Second line: iif is an if/then statement. The format is iif(value (sign), (then), else). This says IF the range is less than 30, THEN X is 10. ELSE it runs the next IF statement. Why 30? Because that's where your values start to change from that flat -10% chance. Same with all of the breakpoints below- the value checked for is the value where the result changes.

Third line: Same thing. IF the range is less than 60, THEN x is 20. ELSE it runs the next IF statement.

Fourth line: Last if/then. This one says IF the range is less than 80, THEN run the formula (30 + ([%Range%] - 60) and set X to that. If not run the formula (50 + (([%Range%] - 80) and set X to that.

The tricky part is keeping all the blasted parathesis straight..

Elsemeravin: you've got it pretty much right. By default all SE5 weapons hit all the time; unless there's some negative number in the to-hit field you'll never miss.
__________________
Phoenix-D

I am not senile. I just talk to myself because the rest of you don't provide adequate conversation.
-Digger
Reply With Quote
  #6  
Old October 14th, 2006, 08:23 AM
President_Elect_Shang's Avatar

President_Elect_Shang President_Elect_Shang is offline
Brigadier General
 
Join Date: Nov 2001
Location: WA
Posts: 1,894
Thanks: 5
Thanked 3 Times in 3 Posts
President_Elect_Shang is on a distinguished road
Default Re: Modding SEV Thread Questions

Ok now I understand and I have to say that formula is a work of beauty. I printed it out as a guide for future formulas. One more question and I think I will be up to par with range.

Let’s say for example that I want to hit a target at range 30 for -20 (80% accuracy). When I set up my formula wouldn’t I want to write the formula for:

Greater than or equal to 21 and less than or equal to 30.

If I don’t explicitly restrict the range I want that one accuracy percent at won’t SE spill it over to the next range IF the next range is undefined? One more time using the example formula you gave; SE will apply the -10 to hit on all ranges from 0 to 30 since your formula said <30 correct?

New question I was reading an earlier post in this thread I came to the impression SE does all ranges in 10’s; which I assume is what you are calling 10 LS, by default. You can change the max range but the base 10’s is programmed. What is the max range; 290 LS?
__________________
President Elect Shang; Tal-Re Republic of Free Worlds
Welcome to Super Vegeta’s Big Bang Attack… Welcome to OBLIVION!
“Don Panoz made an awesome car and… an incinerator” Bill Auberlen
Reply With Quote
  #7  
Old October 14th, 2006, 01:12 PM
Fyron's Avatar

Fyron Fyron is offline
Shrapnel Fanatic
 
Join Date: Jul 2001
Location: Southern CA, USA
Posts: 18,394
Thanks: 0
Thanked 12 Times in 10 Posts
Fyron is an unknown quantity at this point
Default Re: Modding SEV Thread Questions

President_Elect_Shang said:
SE will apply the -10 to hit on all ranges from 0 to 30 since your formula said <30 correct?


Actually, it will apply -10 from ranges 0 to 29. At range 30, you get -20. That is what your chart asked for, right? If it said "<= 30", it would be -10 from 0 to 30 instead.

New question I was reading an earlier post in this thread I came to the impression SE does all ranges in 10’s

No, it does not. Range has a degree of 1, not 10. Actual damage done will be whatever is calculated at the exact range, for example. The damage charts for component display only display every 10 ls because it would be insane to try to show every 1 LS. Also, I think Aaron didn't want to confuse new players by showing the actual formulas.
__________________
It's not whether you win or lose that counts: it's how much pain you inflict along the way.
--- SpaceEmpires.net --- RSS --- SEnet ModWorks --- SEIV Modding 101 Tutorial
--- Join us in the #SpaceEmpires IRC channel on the Freenode IRC network.
--- Due to restrictively low sig limits, you must visit this link to view the rest of my signature.
Reply With Quote
  #8  
Old October 14th, 2006, 02:38 PM
President_Elect_Shang's Avatar

President_Elect_Shang President_Elect_Shang is offline
Brigadier General
 
Join Date: Nov 2001
Location: WA
Posts: 1,894
Thanks: 5
Thanked 3 Times in 3 Posts
President_Elect_Shang is on a distinguished road
Default Re: Modding SEV Thread Questions

Quote:
Phoenix-D said:
The final forumla, or one way of doing it, looks like this:
0 - iif([%Range%] < 30, 10, iif([%Range%] < 60, 20, iif([%Range%] < 80, (30 + ([%Range%] - 60)), (50 + (([%Range%] - 80) * 2)))))
In the case of the example I gave below couldn’t I do something like:

0- iif ([%Range%] <30, 10, iif ([%Range%] <60, 20, iif ([%Range%] <70, 30, iif ([%Range%] <80, 40, iif ([%Range%] <90, 50, iif ([%Range%] <100, 70, iif ([%Range%] <110, 90)))))))
__________________
President Elect Shang; Tal-Re Republic of Free Worlds
Welcome to Super Vegeta’s Big Bang Attack… Welcome to OBLIVION!
“Don Panoz made an awesome car and… an incinerator” Bill Auberlen
Reply With Quote
  #9  
Old October 14th, 2006, 02:48 PM

Phoenix-D Phoenix-D is offline
National Security Advisor
 
Join Date: Nov 2000
Posts: 5,085
Thanks: 0
Thanked 0 Times in 0 Posts
Phoenix-D is on a distinguished road
Default Re: Modding SEV Thread Questions

Looks ok to me.
__________________
Phoenix-D

I am not senile. I just talk to myself because the rest of you don't provide adequate conversation.
-Digger
Reply With Quote
  #10  
Old October 14th, 2006, 02:13 AM

Elsemeravin Elsemeravin is offline
Corporal
 
Join Date: Nov 2001
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Elsemeravin is on a distinguished road
Default Re: Modding SEV Thread Questions

Quote:
President_Elect_Shang said:

Can I make a weapon that will have the following hit probability?

Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 90 – 90 – 90 – 80 – 80 – 80 – 70 – 60 – 50 – 30 – 10
At least you can easily do
Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 100 – 90 – 80 – 70 – 60 – 50 – 40 - 30 – 20 - 10 - 0

by simply adding 100 to the current formula and changing the multiplication factor. However 0 means "hit every time" while 100 would mean that you could have -100 malus from other component and still hit every time..

(Big guys may correct me if I'm wrong on this)
Reply With Quote
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 05:13 AM.


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