View Full Version : Can I get some help?
hivetyrant765
19th Mar 09, 10:49 PM
I want to make a 16-'man' strong hormagaunt squad only cost 8 pop cap, instead of 16. i cant figure out how to do this. can someone post up the code (ebps or sbps), and highlight/bold the section i need to change?
deathblade
19th Mar 09, 11:48 PM
Have you tried editing the ebps file? Under the population_ext, set the personnel_pop to 0.5. I don't know if it will accept that but that's the property you need to edit.
supr3mekill3r
19th Mar 09, 11:54 PM
I did this for my mod, so i'll tell you how to do it.
Under population_ext in the ebps file of troops, you will see "personnel_pop: value", its default for hormagaunts is 1 (as in 1 per hormagaunt).
If you are doubling the squad size but do not want to increase how much population they take up, 1 per unit should now be one-half (0.5) per unit. Same goes for triple/quadruple (one-third and one-fourth and so on).
Mistake I first made was trying to change "popcap" under "cost_ext", this apparently does nothing as far as I know.
XViper
20th Mar 09, 12:18 AM
Hmm... I didn't think 0.5 would work because it could cause the total to not be a full number.
Last time I tried to convert the pop to anything but a full number the .txt would not convert back into a .rbf.
Zetrial
20th Mar 09, 7:50 AM
Viper did you make sure you placed f after 0.5? As soon as you introduce a decimal point you need the f afterwards to indicate a floating point number.
hivetyrant765
20th Mar 09, 9:06 AM
thanks guys. really appreciate the help.
alright, i changed the cost of hormagaunts from 1 to 0.5f, but now they dont cost any popcap.
Yamaeda
20th Mar 09, 3:53 PM
@XViper, i also got a compilation error when doing a similar change, in my case the error was that the compiler didn't recognize the standard abbreviation.
Thus it's imperative to write 0.5f, and not abbreviate to .5f
/Y
XViper
20th Mar 09, 5:11 PM
My change wasn't 0.5, but was something like 1.8, and I'm pretty sure I included the f at the end.
I'll test this again later to check things :)
Although HiveTyrants comment worries me abit :)
hivetyrant765
21st Mar 09, 7:19 AM
still trying to get it to work. i tried it as 0.5, 0.5f, .5, and .5f. the only one that comes close to working is 0.5f, and that causes the squads to have no cost.
i have changed ravenors to 2f, termies, hormies, and rippers to 0.5f, and warriors to 2.5f. all these units have NO population cost, which means i can have as many squads as i want. i even managed to end up at -6/100 once, and i have no idea how that happened.
XViper
21st Mar 09, 7:21 AM
The Raveners with 2 should have definitely worked.
Paste the code you're changing.
You're changing it in the ebps correct?
hivetyrant765
21st Mar 09, 7:41 AM
i am editing the ebps files.
hormie:
| population_ext: {
| | $REF: "entity_extensions\population_ext";
| | personnel_pop: 0.5f;
| | sp_assault_pop: 0;
| | sp_commander_pop: 0;
| | sp_heavy_pop: 0;
| | sp_scout_pop: 0;
| | sp_tactical_pop: 0;
| | sp_total_pop: 0;
| | sp_walker_pop: 0;
| | vehicle_pop: 0;
termie:
| population_ext: {
| | $REF: "entity_extensions\population_ext";
| | personnel_pop: 0.5f;
| | sp_assault_pop: 0;
| | sp_commander_pop: 0;
| | sp_heavy_pop: 0;
| | sp_scout_pop: 0;
| | sp_tactical_pop: 0;
| | sp_total_pop: 0;
| | sp_walker_pop: 0;
| | vehicle_pop: 0;
warrior:
| population_ext: {
| | $REF: "entity_extensions\population_ext";
| | personnel_pop: 2.5f;
| | sp_assault_pop: 0;
| | sp_commander_pop: 0;
| | sp_heavy_pop: 0;
| | sp_scout_pop: 0;
| | sp_tactical_pop: 0;
| | sp_total_pop: 0;
| | sp_walker_pop: 0;
| | vehicle_pop: 0;
ravener:
| population_ext: {
| | $REF: "entity_extensions\population_ext";
| | personnel_pop: 2f;
| | sp_assault_pop: 0;
| | sp_commander_pop: 0;
| | sp_heavy_pop: 0;
| | sp_scout_pop: 0;
| | sp_tactical_pop: 0;
| | sp_total_pop: 0;
| | sp_walker_pop: 0;
| | vehicle_pop: 0;
XViper
21st Mar 09, 8:57 AM
What happens when you make them all 1, 2, 3 etc without the 'f'?
hivetyrant765
21st Mar 09, 9:00 AM
cant convert them back to rbf files.
Netrogor
21st Mar 09, 9:39 AM
The 'f' is essentially a denotation that lets it be recognized as a float value. That way it can work with decimals and the such. Integer bits are generally whole numbers (1, 2, 3, and so forth), whereas a float value can be 1.5, or even 2.7776.
Since the game is set to recognize float values, it is best to keep the 'f' at the end there. ^^
hivetyrant765
21st Mar 09, 9:42 AM
thats the only way i can get it close to working.
setting hormies to 0.5f, for example.
XViper
21st Mar 09, 6:35 PM
My concern is ARE WE SURE that a population value can be a decimal value?
Does the game recognise .5 of a popcap? If you have 3 units at 0.5 each, how can the game display that you're using 1.5 pop?
While I understand that "f" tags it as a float value, the reason I suggested it without the 'f' is that is how the default values are listed. All default pop values are whole numbers without 'f'.
Netrogor
21st Mar 09, 8:06 PM
I am fairly confident that the game can deal with decimals. When you see health regeneration, it adds up decimal values, so it is safe to suggest that this game, which is very CPU intensive, is so because it makes use of the CPU (as well as GPU; pending I setup a second loop for my Radeon HD4870X2, I am leaving the stock heatsink+fan on my video card, and I have to put the fan speed on that up to 50% to avoid having it build up heat on Dawn of War 2).
Anyways, the simplest way to find out, is to test. Set it to count population at 0.25 per unit (as a float value, of course - meaning the 'f' stays). Kill off a few units, until you have four left... add one, see what happens, and keep adding in sets of four. If, after every four units, population goes up one, then it works just fine.
As I said; I am fairly confident you won't run into any problems, and that it will work just fine like that. The devs probably didn't assign those values as floats for show.
XViper
21st Mar 09, 8:45 PM
Well I'd say Hive is testing, and its failing miserably :P
Netrogor
21st Mar 09, 9:20 PM
Hivetyrant, was your problem in getting the modded file to work, or in getting it to convert back into an RBF file, and so forth?
If it was the packing bit, I don't see why, as I can convert it back to an RBF at any given setting (without it becoming 0KB in size).
After I get some sleep, I'll help you out by testing some things on my end. Initially, I thought you were saying that it was a float value by default - didn't think you were trying to change it from an integer into a float by using the denotation 'f'. That changes things, a bit. ^^
Zetrial
22nd Mar 09, 7:01 AM
If setting their pop cap to 0.5f doesn't work then simplest way would probably be leave their cap usage the same and just raise your general cap.
XViper
22nd Mar 09, 7:40 AM
I did abit of testing tonight (although minor), but I also could not get the popcap to recognise a decimal value.
A decimal value without a 'f' at the end, will make the .txt not convert to .rbf
Add 'f' it converts fine, but units ingame do not take up cap.
I think they need to be whole numbers.
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.