view growth.c @ 19:eb8db0d906de

updated runtick.sh to current program
author meillo@marmaro.de
date Wed, 23 Jul 2008 17:44:15 +0200
parents 5937504619f2
children
line wrap: on
line source

#include <stdio.h>
#include <stdlib.h>
#include "db.h"


int grow_plants() {
	sprintf(query,
			"update field "
			"set age = age+1, size = size+1 "
			);
	if (!db_update(query)) {
		db_error("grow plants");
		return 0;
	}
	return 1;
}


int growth(void) {
	return grow_plants();
}