Created
January 10, 2013 18:36
-
-
Save seronis/4504595 to your computer and use it in GitHub Desktop.
print() crashes when called with bldVals oloc = //initialization; oloc.print( pl.toObject().getName() + " oloc" );
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class bldVals { | |
float gcap; | |
float pcap; | |
float city; | |
float farm; | |
float metl; | |
float elec; | |
float advp; | |
float yard; | |
float port; | |
float crgo; | |
float scif; | |
float good; | |
float luxr; | |
float fuel; | |
float ammo; | |
float bnkr; | |
float shld; | |
float cann; | |
float lasr; | |
float peng; | |
void Copy( const bldVals& in rhs ) { | |
gcap = rhs.gcap; | |
pcap = rhs.pcap; | |
city = rhs.city; | |
farm = rhs.farm; | |
metl = rhs.metl; | |
elec = rhs.elec; | |
advp = rhs.advp; | |
yard = rhs.yard; | |
port = rhs.port; | |
crgo = rhs.crgo; | |
scif = rhs.scif; | |
good = rhs.good; | |
luxr = rhs.luxr; | |
fuel = rhs.fuel; | |
ammo = rhs.ammo; | |
bnkr = rhs.bnkr; | |
shld = rhs.shld; | |
cann = rhs.cann; | |
lasr = rhs.lasr; | |
peng = rhs.peng; | |
} | |
void SetAll( float rhs ) { | |
gcap = rhs; | |
pcap = rhs; | |
city = rhs; | |
farm = rhs; | |
metl = rhs; | |
elec = rhs; | |
advp = rhs; | |
yard = rhs; | |
port = rhs; | |
crgo = rhs; | |
scif = rhs; | |
good = rhs; | |
luxr = rhs; | |
fuel = rhs; | |
ammo = rhs; | |
bnkr = rhs; | |
shld = rhs; | |
cann = rhs; | |
lasr = rhs; | |
peng = rhs; | |
} | |
void print( string@ msg ) { | |
print( "---------- " + msg ); | |
print( "- gcap: " + gcap + " pcap: " + pcap + " city: " + city + " farm: " + farm ); | |
print( "- metl: " + metl + " elec: " + elec + " advp: " + advp + " yard: " + yard ); | |
print( "- port: " + port + " crgo: " + crgo + " scif: " + scif + " bnkr: " + bnkr ); | |
print( "- good: " + good + " luxr: " + luxr + " fuel: " + fuel + " ammo: " + ammo ); | |
print( "- shld: " + shld + " cann: " + cann + " lasr: " + lasr + " peng: " + peng ); | |
print( "- " ); | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment