Пример #1
0
void addRawDelay(int delay)	{
	KeywordQueue kWQueue = getKWQueue(NULL);
	Keyword newKey = createKeyword();
	addKWtoQueue(newKey);
	newKey->lCommand = delay;
	addProperty(dTime);
	kWQueue->end->propertiesList[kWQueue->end->nProperties-1]->propertyValue =delay;

}
Пример #2
0
int breakDownWaveCommand(KeywordProp *propertiesList, int nProps)	{
	int n;
	Keyword newKey = createKeyword();
	addKWtoQueue(newKey);	
	newKey->lCommand = makeEnemy;
	KeywordQueue kWQueue = getKWQueue(NULL);
	for(n = 0; n < nProps; n++)	{
		if(propertiesList[n]->p != numberOfEnemies && propertiesList[n]->p != dTime)	{
			addProperty(propertiesList[n]->p);
			kWQueue->end->propertiesList[kWQueue->end->nProperties-1]->propertyValue = propertiesList[n]->propertyValue;
		}
	}
	return n;
}
Пример #3
0
int addGroupCreationDelay(Keyword waveKW)	{
	int dValue;
	KeywordQueue kWQueue = getKWQueue(NULL);
    Keyword newKey = createKeyword();
    addKWtoQueue(newKey);
    newKey->lCommand = delay;
	if((dValue = returnPropertyValue(waveKW,dTime)))	{
		addProperty(dTime);	
		kWQueue->end->propertiesList[kWQueue->end->nProperties-1]->propertyValue = dValue;
		return 1;
	}

	return 0;
}
Пример #4
0
void addKeyWordToken(char *token)	{
		Keyword newKey = createKeyword();
		if(!strcmp(token,"towerPos"))	{
			addKWtoQueue(newKey); 
			newKey->lCommand = makeTowerP;
		} else if(!strcmp(token,"totalWaves"))	{
			addKWtoQueue(newKey); 
			newKey->lCommand = totalWaves;
		} else if(!strcmp(token,"wave"))	{
			addKWtoQueue(newKey); 
			newKey->lCommand = wave;
		} else if(!strcmp(token,"path"))	{
			addKWtoQueue(newKey); 
			newKey->lCommand = path;
		} else {
			fprintf(stderr,"Keyword not recognised\n");
			free(newKey);
		}
}
QString Wellstre::GetPartString()
{
    return createKeyword();
}