Author Topic: Make sure Stockpile Energy has a price.  (Read 2296 times)

0 Members and 1 Guest are viewing this topic.

Offline Anon Zytose

Make sure Stockpile Energy has a price.
« on: April 10, 2014, 03:41:15 AM »
Salutations, everyone! Thank you for creating this site! Also, I'm hoping some of you could help me out here...

I've recently regained interest in putting efforts toward modding the game. First run: A few visible errors caused by invisible line breaks. Still not sure how that happened. More importantly, the second run has a situation where attempting to change production would cause the game to crash inexplicably.

After a great deal of trial and error, I found the source of the game-crashing effect: I had set the price of Stockpile Energy to zero. That cost has since been switched to a single mineral row, but I feel as if I should mention that I learned something: A production cost of zero for an item will crash the game.

That is all for now. First post of mine on this site complete! Thank you!
I'm back from the dead and would very much like to learn how to modify the .exe files.

Online Buster's Uncle

  • With community service, I
  • Ascend
  • *
  • Posts: 49434
  • €183
  • View Inventory
  • Send /Gift
  • Because there are times when people just need a cute puppy  Soft kitty, warm kitty, little ball of fur  A WONDERFUL concept, Unity - & a 1-way trip that cost 400 trillion & 40 yrs.  
  • AC2 is my instrument, my heart, as I play my song.
  • Planet tales writer Smilie Artist Custom Faction Modder AC2 Wiki contributor Downloads Contributor
    • View Profile
    • My Custom Factions
    • Awards
Re: Make sure Stockpile Energy has a price.
« Reply #1 on: April 10, 2014, 03:44:26 AM »
Thank YOU!

That divide by zero error'll get you every time.

Offline Dio

Re: Make sure Stockpile Energy has a price.
« Reply #2 on: April 10, 2014, 03:52:04 AM »
Adding a price to Stockpile Energy has also caused opening unity pods that finish a production at the your nearest base to "complete" stockpile energy.

Online Buster's Uncle

  • With community service, I
  • Ascend
  • *
  • Posts: 49434
  • €183
  • View Inventory
  • Send /Gift
  • Because there are times when people just need a cute puppy  Soft kitty, warm kitty, little ball of fur  A WONDERFUL concept, Unity - & a 1-way trip that cost 400 trillion & 40 yrs.  
  • AC2 is my instrument, my heart, as I play my song.
  • Planet tales writer Smilie Artist Custom Faction Modder AC2 Wiki contributor Downloads Contributor
    • View Profile
    • My Custom Factions
    • Awards
Re: Make sure Stockpile Energy has a price.
« Reply #3 on: April 10, 2014, 03:55:21 AM »
Does that temporarily cause a spike in EC creation by half the value of a row?

Offline Yitzi

Re: Make sure Stockpile Energy has a price.
« Reply #4 on: April 10, 2014, 04:17:13 AM »
Salutations, everyone! Thank you for creating this site! Also, I'm hoping some of you could help me out here...

I've recently regained interest in putting efforts toward modding the game. First run: A few visible errors caused by invisible line breaks. Still not sure how that happened. More importantly, the second run has a situation where attempting to change production would cause the game to crash inexplicably.

After a great deal of trial and error, I found the source of the game-crashing effect: I had set the price of Stockpile Energy to zero. That cost has since been switched to a single mineral row

It's not a single mineral row; if you're using my patch (which you must be, as without my patch the game ignores the "cost" for Stockpile Energy), the "cost" for Stockpile Energy is in minerals rather than rows, and is the number of minerals it takes to produce 1 energy.  So if you set it to 1, stockpile energy will be twice as effective as in the unpatched game; if you don't want to change things, it should be set to 2 (as it is in the version of alphax attached to my patch.)

Adding a price to Stockpile Energy has also caused opening unity pods that finish a production at the your nearest base to "complete" stockpile energy.

Hmm...I didn't expect that to happen.  I'll look into it and provide a fix.

Offline Dio

Re: Make sure Stockpile Energy has a price.
« Reply #5 on: April 10, 2014, 04:36:07 AM »
Here is a screenshot illustrating the bug. There are two bases, one producing stockpile energy and the other a scout patrol.

Offline Yitzi

Re: Make sure Stockpile Energy has a price.
« Reply #6 on: April 10, 2014, 04:38:34 AM »
Ok, I found what it is; there's a rule that if the thing being built is at least 75% done, you can't get a "complete production" pod.  (You can also never get a "complete production" pod for a project.)  At 0 cost, it's always at least 75% done, but with more it isn't.  I think it doesn't make sense for a pod to help "produce" stockpile, so a fix will be along shortly.

(Once it's clear what the bug is, screenshots don't really help much.)

Offline Yitzi

Re: Make sure Stockpile Energy has a price.
« Reply #7 on: April 10, 2014, 04:45:53 AM »
Ok, the patch is posted and ready for approval.

By the way, BUncle, it would actually boost EC creation by the full size of a row (as the amount you get is enough to set it equal to row size times the cost), though you'd lose anything you had left over from last turn.

Offline Anon Zytose

Re: Make sure Stockpile Energy has a price.
« Reply #8 on: April 10, 2014, 04:49:19 AM »
Salutations, everyone! Thank you for creating this site! Also, I'm hoping some of you could help me out here...

I've recently regained interest in putting efforts toward modding the game. First run: A few visible errors caused by invisible line breaks. Still not sure how that happened. More importantly, the second run has a situation where attempting to change production would cause the game to crash inexplicably.

After a great deal of trial and error, I found the source of the game-crashing effect: I had set the price of Stockpile Energy to zero. That cost has since been switched to a single mineral row

It's not a single mineral row; if you're using my patch (which you must be, as without my patch the game ignores the "cost" for Stockpile Energy), the "cost" for Stockpile Energy is in minerals rather than rows, and is the number of minerals it takes to produce 1 energy.  So if you set it to 1, stockpile energy will be twice as effective as in the unpatched game; if you don't want to change things, it should be set to 2 (as it is in the version of alphax attached to my patch.)
That's good to know, thank you. And yes, I am using your patch. Thank you so much for creating it, by the way! :D
I'm back from the dead and would very much like to learn how to modify the .exe files.

Offline Yitzi

Re: Make sure Stockpile Energy has a price.
« Reply #9 on: April 10, 2014, 12:17:41 PM »
Salutations, everyone! Thank you for creating this site! Also, I'm hoping some of you could help me out here...

I've recently regained interest in putting efforts toward modding the game. First run: A few visible errors caused by invisible line breaks. Still not sure how that happened. More importantly, the second run has a situation where attempting to change production would cause the game to crash inexplicably.

After a great deal of trial and error, I found the source of the game-crashing effect: I had set the price of Stockpile Energy to zero. That cost has since been switched to a single mineral row

It's not a single mineral row; if you're using my patch (which you must be, as without my patch the game ignores the "cost" for Stockpile Energy), the "cost" for Stockpile Energy is in minerals rather than rows, and is the number of minerals it takes to produce 1 energy.  So if you set it to 1, stockpile energy will be twice as effective as in the unpatched game; if you don't want to change things, it should be set to 2 (as it is in the version of alphax attached to my patch.)
That's good to know, thank you. And yes, I am using your patch. Thank you so much for creating it, by the way! :D

You're welcome.

 

* User

Welcome, Guest. Please login or register.

Login with username, password and session length

Select language:

* Community poll

SMAC v.4 SMAX v.2 (or previous versions)
-=-
24 (7%)
XP Compatibility patch
-=-
9 (2%)
Gog version for Windows
-=-
103 (32%)
Scient (unofficial) patch
-=-
40 (12%)
Kyrub's latest patch
-=-
14 (4%)
Yitzi's latest patch
-=-
89 (28%)
AC for Mac
-=-
3 (0%)
AC for Linux
-=-
6 (1%)
Gog version for Mac
-=-
10 (3%)
No patch
-=-
16 (5%)
Total Members Voted: 314
AC2 Wiki Logo
-click pic for wik-

* Random quote

The Mind Worms are the natural defenses of the living Planet?the white blood cells, if you will. In a world in which unassimilated thought represents danger, the Mind Worm seeks out concentrations of sentient mental energy and destroys them, ruthlessly and efficiently.
~Commissioner Pravin Lal 'Mind Worm, Mind Worm'

* Select your theme

*
Templates: 5: index (default), PortaMx/Mainindex (default), PortaMx/Frames (default), Display (default), GenericControls (default).
Sub templates: 8: init, html_above, body_above, portamx_above, main, portamx_below, body_below, html_below.
Language files: 4: index+Modifications.english (default), TopicRating/.english (default), PortaMx/PortaMx.english (default), OharaYTEmbed.english (default).
Style sheets: 0: .
Files included: 45 - 1228KB. (show)
Queries used: 38.

[Show Queries]