The problem is that the function is only executed once, you have to add a loop to shift_press:

Code:
function shift_press()
{
	while(1)
	{
		if(!key_shift) press_shift = 0;
		else press_shift = minv(press_shift+0.5*time_step, charge_maximum);
		wait(1);
	}
}



I suggest you have a look at the tutorial: http://tutorial.3dgamestudio.net/


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends