MrFlibble Posted September 13, 2007 Author Share Posted September 13, 2007 Ah, now I remember it: 32767 is the max amount of Spice you can store. After that point is reached, harvesting will actually decrease the amount of Spice you have, and spending it on units or buildings will be for free :D Quote Link to comment Share on other sites More sharing options...
stefanhendriks Posted September 13, 2007 Share Posted September 13, 2007 If i am not mistaken, that is because it is probably an unsigned int. Not a signed one which does not allow < 0. And because Dune 2 does not have a - sign for credits you will not see the difference, only to see the amount of money seems to 'increase' when you buy something, and 'decrease' when you get extra credits. (that is, if you already have reached that max and go over it). Quote Link to comment Share on other sites More sharing options...
TCH Posted September 14, 2007 Share Posted September 14, 2007 You're right about the "increasing" money, but that value is a SIGNED int. Not an unsigned. Earlier i explained the signned/unsigned integers, the highest bit is the sign bit and the value is -2^n => (2^n)-1. If it were an unsigned, then it would be overflow at 65535 and starts again from 0. The Amiga or Sega MegaDrive versions works like this.BTW all of these "bugs" are the Intel CPU's fault. The Intel CPU-s can only work fast with signed max bitwidth values. For example the old Intels wich were 16 bit CPUs, the 16 bit signed Integer. That's why when you look into an exe and see that all value is stored on 16 bit (or 32 if you looks into a win32 file.)That's funny, when the Motorola68000 was invented in 1979 it was a 32 bit processor, and Intel has then the 8086 wich was a buggy half 8, half 16 bit CPU, with a 20 bit addressing wich were segmented to 64k pages.The Motorola 680x0 CPU family (wich were used by the most 16 bit retrocomputer, Amiga, Atari ST, Sega MegaDrive, Machintosh, etc.) can work very fast with any bitwidth values, signed or unsigned either, and they can use 32 bit registers, and they have a flat 24 bit addressing.You can ask then why Intel was the winner in the CPU race. Because of fucking marketing. Just like winsuxx in the OS race.I hate PC-s. Quote Link to comment Share on other sites More sharing options...
stefanhendriks Posted September 14, 2007 Share Posted September 14, 2007 Hey TCH, thanks for the reply (and correction!). I haven't been into that stuff for too long. I am programming too high level these days.So let me get this straight. 16 bit ints where also normal these days. Then 8 bit must be 'shorts'. Ah, but that makes sense as that corresponds to a 'char'. Quote Link to comment Share on other sites More sharing options...
TCH Posted September 14, 2007 Share Posted September 14, 2007 My favourite is the low level programming. But the Intel x86 ASM suxx. Quote Link to comment Share on other sites More sharing options...
Nyerguds Posted March 3, 2008 Share Posted March 3, 2008 I get Java and ASP/C#.NET in schoolat the moment, but I usually end up programming stuff I need in Pascal. Must be because that's what I started with.I can write a convertor for the output of that seeds program MrFlibble attached, but from my first tests they don't seem to contain any Spice.There seem to be some 28 characters for different terrain types though...In the attached file I just randomly replaced them by A,B,C... and eventually went on with 1 and 2 when I ran out of alphabet :PIt gives a nice image of the map though... edges, dunes and all. Just no spice.392_final.txt Quote Link to comment Share on other sites More sharing options...
MrFlibble Posted March 4, 2008 Author Share Posted March 4, 2008 It looks like the converter gets all actual tiles for different spice/rock and rock/mountain border angles, but what's the output type ??? Should it be a graphics image or what?By the way, if you look at the DOS screen when the converter is working, it briefly shows the map in ASCII art, and spice is present (marked by the colon) - see attachment. Quote Link to comment Share on other sites More sharing options...
Nyerguds Posted March 4, 2008 Share Posted March 4, 2008 The actual format is just like that text file, but with binary values instead of letters, no end of lines (it's always 64 chars per line anyway), and with a zero byte padded behind every value. Quote Link to comment Share on other sites More sharing options...
MrFlibble Posted March 30, 2008 Author Share Posted March 30, 2008 By the way, if you look at the DOS screen when the converter is working, it briefly shows the map in ASCII art, and spice is present (marked by the colon) - see attachment.I have redirected the program's output from the screen into a txt file, and it appears that I've been mistaken: it's not spice that is marked by the colon, it's sand dunes. So the program precisely generates all terrain except spice. Curiously enough, the places where spice is located may be occupied by different kinds of terrain, which makes me think that spice fields are somehow imposed later than other terrain when the game generates a map from a seed number. Maybe that's why there's also an option to put additional spice on the maps via the "Field=" line in the INIs.At a second glance, it all seems logical since spice is the only terrain type which can be modified during the game in the sense that spice is eventually harvested away from the map. Quote Link to comment Share on other sites More sharing options...
MuzzNZ Posted April 25, 2020 Share Posted April 25, 2020 Does anyo9ne know if this editor is still avaialable, and will work on 64 bit WIndows 10? Or of any other editors etc. that will work on WIndows 10? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.