O Ilusionista
Captain 80K
For this tutorial, we use script.txt, not script.c. And you should need to put it under the DATA folder.script.c
And no, it doesn't need main or anything like that.
For this tutorial, we use script.txt, not script.c. And you should need to put it under the DATA folder.script.c
Understood, thanks alot.For this tutorial, we use script.txt, not script.c. And you should need to put it under the DATA folder.
And no, it doesn't need main or anything like that.
I just started applying this script to my updated.c for the title screen animation, but somehow it keeps on adding an entity on the screen everytime the engine goes from the intro to the title screen.Understood, thanks alot.
For now, I am just going through your tutorial index list one by one to see which one I can use in my new game. I will start working on it in November or so.
You don't need a globalvar for that. This is handled by this loop:I added the globalvar for spawned entity and kill it with the killentity function, and it seemed to prevent from the addition.
if(openborvariant("in_titlescreen"))
{
void counter = getlocalvar("counter");
counter = setlocalvar("counter",0);
}
What I meant wasYou don't need a globalvar for that. This is handled by this loop:
C-like:if(openborvariant("in_titlescreen")) { void counter = getlocalvar("counter"); counter = setlocalvar("counter",0); }
void counter = getlocalvar("counter");
counter = setlocalvar("counter",0);
openborvariant("in_options")
Then you have to change the code - this code is spawning an entity on the select screen, not in the title screen.I want the spawned entity to disappear completely in the intro, then reappears whenever the engine is back to the title screen again.
I had this code in the title screen:Then you have to change the code - this code is spawning an entity on the select screen, not in the title screen.
Here is an update version I am using on my MMPR project - I have different entities for TITLE and SELECT screen:
{
void counter = getlocalvar("counter");
void vSpawn;
while(counter!=1)
{
void subent;
loadmodel("bgfx"); // name of the entity to be loaded
clearspawnentry(); // clean the spawn entry
setspawnentry("name", "bgfx"); // define the entity to be spawn
setspawnentry("coords", 1,0,-1); // set the position of the entity
subent=spawn(); // spawn the entity
changeentityproperty(subent, "position", 1,0,-1); //for safe, set again the position
counter = setlocalvar("counter",1); // turn on the variable, blocking a new spawn to be made
}
}
void counter = getlocalvar("counter");
counter = setlocalvar("counter",0);