August 8, 2001, 18:58
|
#31
|
King
Local Time: 11:38
Local Date: October 31, 2010
Join Date: Jan 2000
Location: Gone Fishin, Canada
Posts: 1,059
|
Quote:
|
I'm having problem with the messages. The lines {theNearestCity.name} and {PlaguedCityCounter} doesnt seems to be working.
|
Good to see someone else getting interested in SLIC!
1) In your messages, replace {player[0].name} with {player[0].civ_name_singular}. You can find other options in the documentation on BuiltIn variables.
2) In ND_func.slc, cut out the declaration "int_t PlaguedCityCounter;" and paste it to a line just above the function declaration "void_f Plague (int_t thePlayer){". To use it to send data to the screen, it needs to be a global variable.
3) I haven't been able to pin down the problem with the quake messages yet but will get back to you as soon as I can.
|
|
|
|
August 18, 2001, 07:24
|
#32
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Hello!
Firstly, thanks everyone for the comments.
Pedrun, you are correct in assuming that the file was a test, and that was the reason for the messages every turn. One thing I want to sort out is how often these events should occur, bearing in mind the size of the world, and time-scaling.
Quote:
|
(by the way shouldnt i loose the city if it was working?)
|
For earthquakes, the loss of population is done as a percentage of the city's total population, so a city will never be destroyed. I have adjusted the plague event so it now only hits cities sized 3 or more.
I am puzzled about the earthquakes effect. There is no code in the earthquake function as yet to make terraforming happen. I reasoned that quakes either cause rifts, mountain ranges or flooding. The easiest way would be to make it dead, but I don't think that would happen, and to do it too realistically ould be rather difficult. Maybe in later versions.
The volcanoes should create dead tiles, even in the water. I think this is quite a good effect, and I have endeavoured to code it so that the tiles regenerate over time, and turn into grassland. As Jani suggested, it is very difficult! Also, dead tiles will stay dead if you have conservation, as the corporations backlash or something...
Clarifyer: Plagues and epidemics are the same, they just change name after you discover medicine. Its that simple  I just thought that nowedays, we never get plagues as such, because antibiotics in most places with "modern medicine" can stop them, but we do get epidemics, like AIDS in South Africa and 'flu in South-East Asia. Just a minor thing really.
Wes did express some interest in putting Natural Disasters into the MedPack, but I think only once they have been properly completed, debugged and double debugged, and rigorously tested to calculate its affect on the human's gameplay and more importantly, that of the AIs'.
Thanks Peter for sorting out those messages, I get the feeling I'm still learning this...
Next update soon.
Ben
|
|
|
|
August 18, 2001, 09:47
|
#33
|
Emperor
Local Time: 06:38
Local Date: October 31, 2010
Join Date: Jun 1999
Location: Smemperor
Posts: 3,405
|
Welcome back Ben,
My citizens still need some more death and destruction in Cradle - after all, the ancient world is a cruel and hard place.
Can't wait to customize the messages too.
'The gods are angry with the lack of devotion from your people - your empire has been smitten with an evil pestilence. Grovel and plead for mercy and they may yet relent.'
Something along those lines...
__________________
Yes, let's be optimistic until we have reason to be otherwise...No, let's be pessimistic until we are forced to do otherwise...Maybe, let's be balanced until we are convinced to do otherwise. -- DrSpike, Skanky Burns, Shogun Gunner
...aisdhieort...dticcok...
|
|
|
|
August 18, 2001, 23:00
|
#34
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
Welcome back IW. We all missed you.
Quote:
|
Originally posted by Immortal Wombat
One thing I want to sort out is how often these events should occur, bearing in mind the size of the world, and time-scaling.
|
My thoyghts to all kinds of maps:
Volcano: every 120-180 turns
EarthQuakes: every 20-50 turns
Plagues: every 10-30 turns
Quote:
|
For earthquakes, the loss of population is done as a percentage of the city's total population, so a city will never be destroyed. I have adjusted the plague event so it now only hits cities sized 3 or more. There is no code in the earthquake function as yet to make terraforming happen. I reasoned that quakes either cause rifts, mountain ranges or flooding. The easiest way would be to make it dead.
|
 I guess you are right. I just think quakes should not create dead tiles in water since they are a too common disaster (too many dead tiles islands  ).
Quote:
|
The volcanoes should create dead tiles, even in the water. I think this is quite a good effect.
|
Yes it is a great effect. But it should rarelly occur in the frequency i told you up this post.
Can you make a list of the exacly consequences of every disater?
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
Last edited by Pedrunn; August 19, 2001 at 05:42.
|
|
|
|
August 19, 2001, 07:56
|
#35
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Quote:
|
'The gods are angry with the lack of devotion from your people - your empire has been smitten with an evil pestilence. Grovel and plead for mercy and they may yet relent.'
|
LOL  Loving it. Shall I make a special "thunder-bolt" disaster that only affects theocracies which are too happy?
Quote:
|
Welcome back IW. We all missed you.
|
Quote:
|
My thoyghts to all kinds of maps:
Volcano: every 120-180 turns
EarthQuakes: every 20-50 turns
Plagues: every 10-30 turns
|
Sounds ok, I assume you mean every x Human-turns, because technically there is 8 turns for each human turn...
Quote:
|
Can you make a list of the exacly consequences of every disater?
|
Yes I can...
So far, I have:
- Earthquake
- Only affects mountain tiles, subject to change.
- Comes in Richter 1 - Richter 8
- 3% chance of R8, 5% of R7, 10% of R6 10% of R5, 12% of R4, 15% of R3, 15% of R2, 30% of R1.
- If there are 2 beaches nearby, the Richter is 3/2 the force it was originally determined as. (signifying destructive plate boundary)
- If there is a city:
- Damages units more or less depending on Richter
- Kills a percentage of population (50% for R7+, 33% for R5+, 25% for R2+)
- Makes unhappiness, again amount and duration dependant of Richter strength.
- Destroys buildings. If the city has arcologies, the chance of destroying each building is much smaller. Then the force of the quake determines how likely it is for each building to be destroyed. (arcologies are never killed by quakes)
- Then, if no city, on the square it is on, cut improvements.
- Then... Searches the 8 surrounding tiles, and the for tile improvements, and for R7 and R8 the 16 surrounding them, and in a pattern that Peter did, pillages the tile improvements there.I'm not sure of the exact pattern, but the greater the strength, the more is destroyed.
- Plague
- Currently only affects humans.
- Will occur every 20 turns

- For each city owned, there is at the start, a 50/50 chance of infection
- The chances of infection drops 10% each with any aqueduct, drug store, hospital and aqua-filter you have in the city.
- The plague then kills 1/3 the cities population.
- and causes -2 happiness for 3 turns.
- Volcano
- Can occur on mountain tiles
- Searches for nearby beaches again. If yes, then the force is up to 8. In no, then up to 4.
- Or can occur at sea, in rifts and volcanos, where the force can be up to 6.
- On the volcano, cut improvements, and damage units
- If it is a city, kill 'force' pop points.
- and destroy buildings using the same chance as quakes, only arcologies provide less protection.
- Then find a 'force' number of random neighbouring tiles:
- Cut improvements there
- Make the tile dead, and, then if the tile owner does not have conservation, make it slowly regenerate to plains.
- If there is a city there, then kill 1/3 of its population.
Last edited by Immortal Wombat; August 19, 2001 at 08:01.
|
|
|
|
August 19, 2001, 13:45
|
#36
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
As far as i tested the plage event is working great decreasing pop, causing unheppines and spreading to near by cities.
The earthquake is killing people, making them unhappy and only happening in mountains but i havent seen it killing units yet :hmm:. I did not test the volcano.
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
|
|
|
|
August 19, 2001, 13:49
|
#37
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
dp
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
|
|
|
|
August 19, 2001, 16:53
|
#38
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Good to see it working okay. The units will probably only be damaged, and perhaps only slightly at that. If they are in cities, chances are that they will heal too quickly for the effect tto be noticed, and I don't think that effect will have much impact on the game.
|
|
|
|
August 27, 2001, 15:54
|
#39
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
Quote:
|
Originally posted by Immortal Wombat
Good to see it working okay. The units will probably only be damaged, and perhaps only slightly at that. If they are in cities, chances are that they will heal too quickly for the effect tto be noticed, and I don't think that effect will have much impact on the game.
|
This code kind of became forgotten this week. But IW could you attach it here ready for use and not as a test like the last one?
I want to start a new game now with the natural disasters in.
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
|
|
|
|
August 27, 2001, 17:19
|
#40
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Sorry, I've been a little busy lately, exam results coming through, and all the related drunkeness that goes along with that  I should post a "final" test tommorrow, and then it will just need playtesting to completion.
|
|
|
|
August 27, 2001, 18:02
|
#41
|
Settler
Local Time: 06:38
Local Date: October 31, 2010
Join Date: Aug 2001
Location: south florida
Posts: 6
|
I think the idea for earthquakes and other natural disasters is a good idea. Why hasn't anyone constructed volcanoes on the surface. A volcanic eruption on the surface can cause earthquakes and temporarily destroy the tiles a certain distance from the eruption. I Know i am getting far ahead of myself and you have been doing a lot of work but just another ideas to put in the pot. By the way hurricanes is a pretty good idea been wondering why there are no weather features in these games.
|
|
|
|
August 28, 2001, 09:29
|
#42
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
ah, but exam results (3A*, 6A, 1B) + drunkeness = happy Ben
Sorry, but more drunkeness tonight, so disasters shall have to wait again
|
|
|
|
August 28, 2001, 09:53
|
#43
|
Emperor
Local Time: 06:38
Local Date: October 31, 2010
Join Date: Jun 1999
Location: Smemperor
Posts: 3,405
|
Quote:
|
Originally posted by Immortal Wombat
Sorry, I've been a little busy lately, exam results coming through, and all the related drunkeness that goes along with that I should post a "final" test tommorrow, and then it will just need playtesting to completion.
|
Drool, drool!!!
Hey Ben, drunkeness + exams = cook at McDonalds
__________________
Yes, let's be optimistic until we have reason to be otherwise...No, let's be pessimistic until we are forced to do otherwise...Maybe, let's be balanced until we are convinced to do otherwise. -- DrSpike, Skanky Burns, Shogun Gunner
...aisdhieort...dticcok...
|
|
|
|
August 28, 2001, 10:06
|
#44
|
Prince
Local Time: 11:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: Orlando, Florida
Posts: 326
|
Yeah, or, in CTP2 terms, its like those middle sized cities producing -46 gold. Thats what screwing up exams are like.
__________________
Bluevoss-
|
|
|
|
August 28, 2001, 10:22
|
#45
|
King
Local Time: 11:38
Local Date: October 31, 2010
Join Date: Jan 2000
Location: Gone Fishin, Canada
Posts: 1,059
|
I don't think you guys understand. His exams were finished months ago; those are his results. IIRC, A is like Grade Point 4 and A* is 'with distinction'. Congratulations, Ben.
|
|
|
|
August 28, 2001, 12:16
|
#46
|
Emperor
Local Time: 06:38
Local Date: October 31, 2010
Join Date: Jun 1999
Location: Smemperor
Posts: 3,405
|
D'oh, we Americans are such idiots...  Guess I should read the post more carefully.
I guess Ben won't be working at McDonalds then!!! That's why he is the SLIC writer and I am not.
Congrats
__________________
Yes, let's be optimistic until we have reason to be otherwise...No, let's be pessimistic until we are forced to do otherwise...Maybe, let's be balanced until we are convinced to do otherwise. -- DrSpike, Skanky Burns, Shogun Gunner
...aisdhieort...dticcok...
|
|
|
|
August 29, 2001, 04:11
|
#47
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
That last zip was just the files that were going wrong, I have now figured out my stupidity, and got it down to one error message per tsunami (8 per turn  )
I can't figure out how:
Code:
|
tmpPlayer = tmpCity.owner;
message(tmpPlayer, 'THU');
if(tmpPlayer != ND_human){
message(ND_human, 'THO');
} |
Can cause an error 
Apparently, in "object Tsunami, function _message: incorrect arguement" I don't know...
Anyway, I'll sort it tommorrow, when I'm not half-asleep
|
|
|
|
August 29, 2001, 05:29
|
#48
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
Quote:
|
Originally posted by Immortal Wombat
I should post a "final" test tommorrow, and then it will just need playtesting to completion.
|
When i said not as a test like the last one i meant the disasters not happening every turn to be possible a whole game of testing (as a thought the final one) and of course enjoyment.
Congratulations, really impressing marks  . And good drunkness (what am i talking about drunkness is always good  ).
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
Last edited by Pedrunn; August 29, 2001 at 05:37.
|
|
|
|
August 29, 2001, 10:28
|
#49
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Thanks guys, yeah, my exams were in July, and I got the results last thursday. I'm quite pleased with them.
The next (and hopefully final) version I shall post will be a test only in as much as I want to get some playtesting before announcing it "done". This is so I'm not caught up in updating it to make it compatible with MedMod, 'Poly-pack and Cradle separately. I spent a merry hour making sure all the variables that the code shared with other SLIC in use were localised, and all the rest were different
I have an error message that I never got before though! I think its to do with the way I make the tiles regenerate.
It says: "Prototypes should not define arguements"
The messages are still not fully written yet, these are just place-holders, but all 4 files (and scenario.slc and strings.txt) are included:
|
|
|
|
August 29, 2001, 12:19
|
#50
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
I really did not had a good experience with it.
When loading CTP2:
"Prototypes should not define arguements"
I got this message. Another one about a syntax error in line 645.
When starting a game:
The same messages.
And looks like the code did not liked my scenario.slc.
I get about ten messages about it saying that there are undefined codes in the first lines and lines 160 and 161.
What is stranger is that in it there is only some #include "*.slc" and the destroy tile imp code you wrote. A total of 40 lines. So i am not even close of 160.
Then the games freezes
Maybe i should wait for others people experience.
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
Last edited by Pedrunn; August 29, 2001 at 12:28.
|
|
|
|
August 30, 2001, 19:46
|
#51
|
King
Local Time: 11:38
Local Date: October 31, 2010
Join Date: Jan 2000
Location: Gone Fishin, Canada
Posts: 1,059
|
Sorry I haven't been much help lately. At the beginning of the month I downloaded the Activision WW2 scenario and I've been spending almost all my spare time trying to re-SLIC it. I'm determined to get something finished for a change. I think it's almost finished now so I took a day off from it today.
Have you had any luck with that prototype error? I thought it might have something to do with:
Quote:
|
Important note! As this documenation is being prepared, the first patch for CTP2 is about to be released. Unfortunately a bug with functions was discovered too late to fix. Specifically, in some cases, using members of unit, army, city, and location variables that are function parameters may not always work as expected. There is, however, a workaround. Copy the function parameter to a local variable and use that variable instead.
Code:
|
Example: // This version may fail sometimes!
int_f DoesAHumanOwnThisUnit(unit_t theUnit) {
if(IsHumanPlayer(theUnit.owner)) {
return 1; }
return 0; }
// This version should always work
int_f DoesAHumanOwnThisUnit(unit_t theUnit) {
unit_t copiedUnit;
copiedUnit = theUnit;
if(IsHumanPlayer(copiedUnit.owner)) {
return 1; }
return 0; } |
The author apologizes for this and promises that if there is another patch it will be fixed. But the above workaround should always work.
|
But when I tried the suggested workaround I got a crash to desktop and it resized my screen. That sort of thing makes me nervous.
Last edited by Peter Triggs; August 30, 2001 at 19:56.
|
|
|
|
August 31, 2001, 05:18
|
#52
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
I solved the prototypes problem, I was being a moron. I started a function:
void_f FunctionName (location_t theLocation);
when obviously the ; should have been a {

I'm getting a really wierd bug now, in the tsunami messages. I'm sure they are exactly the same as other messages, but it gives an error, saying the arguement is wrong.
|
|
|
|
September 4, 2001, 07:11
|
#53
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
With DebugSlic set to Yes, I get an error message, with it set to No I get a crash whenever a tsunami hits, and I cannot figure out the problem.
Other than that, its finished for now I think.
Test version, disasters every turn, with known problem:
__________________
Concrete, Abstract, or Squoingy?
"I don't believe in giving scripting languages because the only additional power they give users is the power to create bugs." - Mike Breitkreutz, Firaxis
|
|
|
|
September 4, 2001, 08:56
|
#54
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
Oh oh I'm experiencing game crashs in the firsts 10 turns, after getting a lot of diseses averted by my medics quick thinking. So i guess it is a problem with the plagues.
Didnt you set plagues to be in cities 3 or bigger?
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
|
|
|
|
September 4, 2001, 15:56
|
#55
|
King
Local Time: 11:38
Local Date: October 31, 2010
Join Date: Jan 2000
Location: Gone Fishin, Canada
Posts: 1,059
|
The crash seems to be being caused by the line:
Code:
|
if(!CityIsValid(tmpCity) && MessageCount < 1){
// if it is NOT there, and we've not messaged before |
I have no idea why, but after playing around for a bit and outcommenting sections of code, that's the one it narrowed down to.
BTW, I've got an idea for a new project, but it needs to be done quickly. I'll write something up and e-mail you later tonight.
|
|
|
|
September 4, 2001, 16:21
|
#56
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Hmm, interesting...
*frantically checks email every 5 minutes from 9:00 til 1:00*
Thanks Peter
__________________
Concrete, Abstract, or Squoingy?
"I don't believe in giving scripting languages because the only additional power they give users is the power to create bugs." - Mike Breitkreutz, Firaxis
|
|
|
|
September 6, 2001, 18:13
|
#57
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Right, I'll get this finished ASAP now...
Here are the files, final beta, there should be no problems, but I have yet to write up the readme etc...
To include the files, open scenario.slc, add the line
#include "ND_main.slc"
open strings.txt, add the line
#import "ND_str.txt"
Then play!
Feel free to change the messages in ND_str, they are probably subject to changes, but I have just gone back to school, and am pressed for time. I know whatever I put, Dave will change, so why bother? Customize yourselves people!
__________________
Concrete, Abstract, or Squoingy?
"I don't believe in giving scripting languages because the only additional power they give users is the power to create bugs." - Mike Breitkreutz, Firaxis
|
|
|
|
September 7, 2001, 13:27
|
#58
|
King
Local Time: 08:38
Local Date: October 31, 2010
Join Date: Jul 2001
Location: of Natal, Brazil
Posts: 2,555
|
I test it although it isnt a test file anymore. All seems to be working all right so far.
I did took the line off in the plague event to happen with the AI too. It gave me a error message. No biggy though since all worked fine with the line.
This code really is a masterpiece  .
__________________
"Kill a man and you are a murder.
Kill thousands and you are a conquer.
Kill all and you are a God!"
-Jean Rostand
|
|
|
|
September 8, 2001, 00:30
|
#59
|
Emperor
Local Time: 06:38
Local Date: October 31, 2010
Join Date: Jun 1999
Location: Smemperor
Posts: 3,405
|
Loaded up on Cradle - will be starting a new game sometime this weekend hopefully (if time permits). No crashes in the trial run through the cheat mode - though I merely launched the game without playing any turns. I had a lot of stuff to add and tweak this week.
As always, I'm looking forward to the new SLIC file that you did Ben
And it will be bundled with the next update.
__________________
Yes, let's be optimistic until we have reason to be otherwise...No, let's be pessimistic until we are forced to do otherwise...Maybe, let's be balanced until we are convinced to do otherwise. -- DrSpike, Skanky Burns, Shogun Gunner
...aisdhieort...dticcok...
|
|
|
|
September 8, 2001, 07:03
|
#60
|
Prince
Local Time: 12:38
Local Date: October 31, 2010
Join Date: Dec 2000
Location: in perpetuity
Posts: 4,962
|
Hmm, I'm glad it seems to be working... Have you guys got DebugSlic on Yes or No?
Also, could you do a test? Set the chance of getting a tsunami 100%, and make sure you have one, it is still causing problems for me.
Pedrunn, when you took the line off, did you take off the close bracket line further down (I think I marked it...) That should prevent any error message.
Thanks!
Ben
--> with readme. Don't overwrite the other files in case they work, and the update doesn't
BTW everyone, the files have about 8 downloads each. I count Peter Dave Pedrunn and Bluevoss in this thread  Who are you all??
__________________
Concrete, Abstract, or Squoingy?
"I don't believe in giving scripting languages because the only additional power they give users is the power to create bugs." - Mike Breitkreutz, Firaxis
|
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is On
|
|
|
All times are GMT -4. The time now is 07:38.
|
|