Hi.I suggest a function that returns the graph number from the name of it (the name you can see in the FPg editor).
For exemple :
graph = "my_graph_name";
Bennu automatically search the identifier of the graph in the GIF assigned to the process.
Wouldn't that be wonderful? :)
It could be, but it could also be terrifyingly slow and unoptimized.
If you're interested in something like that, I recommend you to create a function to sort it out.
It would be something like this:
function graph_me(int file,string name);
begin
father.file=file;
from x=1 to 999;
if(map_exists(file,x))
if(MAP_GET_NAME(file,x)==name)
return x;
end
end
end
return 0;
end
Process something();
Begin
graph_me(fpg_character,"stand1");
End
But.... there's no function to retrieve the name of the graphic from the FPG, so that way won't directly work (I think)
maybe a function like "map_get_by_name" or "map_get" or "map_find", that use "name" as parameter...