Jump to content

  • Log In with Google      Sign In   
  • Create Account

suliman

Member Since 19 May 2004
Offline Last Active Jun 17 2013 07:46 AM
-----

Topics I've Started

(Matlab) handles not updating

29 May 2013 - 08:10 AM

Hi

I have a gui and i run this function to get some data and store it in handles.

function 
updateButton2_Callback(hObject, eventdata, handles)

[handles.allPark,count,handles.allParkData]=allPark();
d=handles.allPark;

str=sprintf('(based on prodData)\n\nTurbines: %.0f \nLosses: %.1f %% \nPeriod: %.1f yrs\n\nTotal losses: %.1f GWh\nTotal prod: %.1f GWh',count,d(1),d(4),d(2),(3));
set(handles.resultsPark,'String',str);
guidata(hObject, handles);

I use it in another callback and the data is there and works. But sometimes (not always) when i run another loadFunction (depending on the data) those data (handles.allPark for example) is set to zero.

 

How can it be set to zero? The only time i set handles.allPark=0 is in the openingFcn and it is not run other then at startup (i have checked).

 

Is this connected to that i sometimes have to run: (got this tip from the net and it solved another handles-related problem)

handles = guidata(hObject);

Altough i dont understund why such an updata is needed...

 

Im very confused. Thanks for any help

Erik


Name for nation focus/doctrine

28 May 2013 - 12:40 AM

Hi

Im doing a turn-based (tabletop) strategy game in a cold war setting where you control a superpower.

Each turn is around half a year and the player can choose a focus/doctrine for the "empire". Holding the same focus for 3 turns gives a bonus in that "style" of play (sort of nation "specialization").

 

But focus is a bit boring, doctrine sounds cooler but maybe that means something else? What else can it be called? (maxim, axiom i dont know...)

Also, the names for the actual "focuses" your nation can hold (below)? Any suggestions for improvements on the names?

 

Aggression (bonus to attacks, penalty for def)

Security (bonus to def)

Industry (bonus income)

Mobilization (produce military units)

Intelligence (get special cards and protects against spies)

 

Thanks for your input!

Erik


Names for soldier ranks?

18 May 2013 - 07:37 AM

Hi
Im looking for names for soldier ranks in a semi post-apoc setting. Its urban fighting between criminal gangs, militias, guerilla factions. My fist batch is this:
 
Recruit
Grunt
Footman
Trooper
Sergeant
Lieutenant
Captain
 
Might have 2 more levels. But any other ideas? Could be "titles" from hells angels, mafia, streetgangs of rio de janeiro, survivalist right-wing militia, mountain guerilla etc. What nice ranks could i use?

I like the semi-military style but feel free to go nuts! Should suit people who actually fight, not leader/commander titles like "general" or "chairman". Could also be mixed up like
 
street sergeant
some other sergeant rank
 
E

calculate relative humidity?

06 May 2013 - 07:52 AM

Hi

 

Do i need tables with known data to do this? I got my data series as:

 

q      Water vapor mixing ratio in kg/kg
cw    Cloud water mixing ratio in kg/kg

t       temp in kelvin

p      pressure in HPa

 

How would i get the relative humidity?

 

Thanks a lot!

Erik


PARTNERS