Home Crush your enemies... and create an EMPIRE!!! Space Empires V -- BUY NOW!!!

User login

  • Create new account
  • Request new password

Navigation

  • news
    • archive
    • blogs
    • books
    • forums
    • recent posts
    • groups
  • image galleries
  • projects & downloads
  • search
  • create content
  • news aggregator

Search

Who's online

There are currently 2 users and 153 guests online.

Online users

  • Randallw
  • whitewolfmxc

Languages

  • English English
  • French French

Browse archives

« Juillet 2008  
Lu Ma Me Je Ve Sa Di
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31      
Home » news » forums » Support & Feedback » Scenarios & Mods » SE:V MODs

AI surrender

Submitted by Lastdreamer on Tue, 2008-01-29 07:46. SE:V MODs

Scrolling all the files in Utilities Folder, I've seen a strange thing... this one:

// Do we surrender?
set perform_surrender := (pct_compare >= lng_Politics_Min_Score_Pct_Diff_To_Surrender)

if (perform_surrender) and (Sys_Get_Random_Long(1, 4) >= 2) then
set perform_surrender := FALSE
endif
if (not Sys_Are_We_Computer_Player(sys_long_Player_ID)) then
// Ministers used by human players should never surrender.
set perform_surrender := FALSE
endif
if (Sys_Is_Game_Using_Teams()) and (from_plr > 0) then
if (not Sys_Empire_Politics_Is_Player_On_Our_Team(sys_long_Player_ID, from_plr)) then
set perform_surrender := FALSE
endif
endif

It seem that for letting an AI to surrender, you must have more point (seeing Global Variables, I see you must have five time the point), but also the random number must be 2/3/4, so, if you have more than 5 time point you have 75% possibility of successfull requesting the enemy empire to surrender. But in all this code there is one little BUG... here:

if (perform_surrender) and (Sys_Get_Random_Long(1, 4) >= 2) then
set perform_surrender := FALSE
endif

this part of the code say that if you have more than five times point (perform_surrender) and the random number is 2 or more (Sys_Get_Random_Long(1, 4) >= 2) then the enemy empire DON'T surrend!!! (set perform_surrender := FALSE)

Changing the FALSE to TRUE the enemy empire would surrender... not?

‹ Damage Types How does this work?? (Get function) ›
» login or register to post comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Unole's picture

Re: AI surrender

Submitted by Unole on Tue, 2008-01-29 08:07.

That depends on how easily you want the enemy empire to roll over and play dead. If you change (Set perform_surrender := FALSE) to (set perform_surrender := TRUE) then yes, the enemy empire will surrender MORE OFTEN. 75% chance of surrender. The current programming only allows a 25% chance of a surrender. I like to think of my enemies as arrogant and prideful enough to fight to the death. Which I am quite content to provide to them.

Unole!
Directive 721: Cover your own a$$ first. Solo

» login or register to post comments

Re: AI surrender

Submitted by Lastdreamer on Tue, 2008-01-29 08:37.

Ehm...you're right... I've make a mistake... sigh... sorry!!!

» login or register to post comments
Unole's picture

Re: AI surrender

Submitted by Unole on Tue, 2008-01-29 12:05.

No, not a mistake. Just a different way to look at the programing. I've learned from this just where to make it MORE difficult for the AI to surrender. Thanks

Unole!

Directive 721: Cover your own a$$ first. Solo

» login or register to post comments

Re: AI surrender

Submitted by Lastdreamer on Tue, 2008-01-29 15:01.

Well, then... not at all!!! Glad to help you in this way!!! ;-P

» login or register to post comments

Re: AI surrender

Submitted by Vince278 on Tue, 2008-01-29 20:47.

I can't remember now the last time anyone surrendered to me, even when they were crushed. Perhaps my reputation precedes me. Laughing out loud

» login or register to post comments

Re: AI surrender

Submitted by AndreyKl on Thu, 2008-01-31 04:32.

if default meaning of perform_surrender := FALSE
then AI will never surrender, at the start should be string perform_surrender := TRUE

» login or register to post comments

Re: AI surrender

Submitted by Lastdreamer on Thu, 2008-01-31 08:06.

No, the AI will surrender at 25% of the case, becuase here:

set perform_surrender := (pct_compare >= lng_Politics_Min_Score_Pct_Diff_To_Surrender)

the "perform_surrender" is set to TRUE if the different point between the two empire is of 500% or more. Only after this declaration there is the random control:

if (perform_surrender) and (Sys_Get_Random_Long(1, 4) >= 2) then
set perform_surrender := FALSE

Where, if you point difference is more than 500% (perform_surrender) and if the random number is 2/3/4 (sys_get_random_long(1, 4) >= 2) then the empire wouldn't surrender.

IF you have al least 500% point of the surrending empire (difficult to make...) AND the number generated random is 1 then the enemy empire will surrender. As Vince278 says, I don't remember when the last race surrender to me...

» login or register to post comments

Re: AI surrender

Submitted by Vince278 on Thu, 2008-01-31 21:03.

I'll have to check those settings. Smiling

» login or register to post comments

Re: AI surrender

Submitted by TheStuff07 on Sun, 2008-02-03 17:05.

The AI has never once surrendered to me in SEV since I bought the game the day it came out, nor in the demo the months preceding. 25% chance my ass. lmao. I can send an enemy that I've completed dominated, have over 10x the score of, 10 messages demanding their surrender every turn for 20 turns and never get a single surrender. I can have them down to a single planet with 125M and no way to get off the planet, surround the planet with my ships, and even move a ship onto the same sector as their planet that won't attack them, and they still don't surrender. I remember them saying they did an update to fix that, too, and apparently it didn't work.

Based on that, the code that says surrender=false means that they will never surrender, and the true means they will 25% of the time, unless you've changed the %. I do the same thing with every race, I try to get the maximum population I can, fill up planets that have the wrong air type for my people and let the new race use those planets. But out of the thousands of races I've crushed, not a one has surrendered to me. The only time I've ever seen anyone surrender is when a race rebels from the AI and the AI gets it back 2 turns later.

» login or register to post comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Now on STEAM

Now on STEAM!Space Empires V via STEAMSpace Empires IV via STEAMSTEAM online by Valve Corporation

Popular content

Today's:

  • Research By Percentage SUCKS
  • Cloaked Warp Points
  • Capturing suicidal colony ships of Balance Mod AI empires
  • Space Empires V 1.74
  • Space Empires V

All time:

  • Space Empires V and VI: Expansions and the Future: Tell the Company What's on Your Wish List
  • Space Empires V
  • Gritty Galaxy Fleet Clash
  • Damn Dirty Bugs/Annoyances
  • Space Empires V: General Thoughts, Observations, and Suggestions

Last viewed:

  • How do I add pictures for new Tech's that I create?
  • Just an odd little something
  • Is the game playable at 1.33
  • 2 armor questions (That got answered! Thanks much)
  • Are the Beta Teasters reading this Forum?
(c) Strategy First, Inc. All rights reserved.