Using AGE as a more practical and stable TAGNAME

nadeauhugo

Author of FOT mod THE SUM
Modder
I recently found that whenever time pass, the age of the main character (or any character) variable will never ever go up. At first I was VERY FRUSTRATED ABOUT THIS. The age in game will appear changed after a year, but it is due I think only to a hardcoded calculated formula, not to the age variable really changing...

But!!! There is something else to do with it, since the age have totally no gameplay value in this game and can't even be used for something. So I decided to hide it (very simple, you just have to replace core/gui/btn/cage_up.zar and core/gui/btn/cage_dn.zar with a 1x? invisible png) to use it as a hidden tagname. All my prefab char have the age of 1,2,3,4,5,6...., which is the best and more stable way for me to identify them during the game and change my dialogues/endings/events according to the character actually used. Can be very powerfull if you want your mod to be played by a human, a ghoul and a supermutant, for example, and want them to appear at three different starting points. You can even use the age later to make the two other races enemy of the player...

There may be also a way with this method (I didn't tried it yet), to identify a custom made character (age 19 by default - no change possible because de button is invisible - or something else?)

The nice thing about this method is that you then can use the TAGNAME for something else!! Use a single TAGNAME for all characters to identify the player in any situation, such as "player". This can be very useful for many things, such as moving the player instantaneously to another mission/area as with an elevator, or moving objects close to the player, or making the main player anwser to another character after he/she spoke. When cracking BOS.EXE to make the tagname stop being ereased, you can give the character a tagname only once using the first Spawning point he will appear in! Very great!

I would like to use also the variable "sex" to identify the player as a male or female for dialogue purpose, but I didn't try it yet. Somebody know what value it can get, like "male" and "female"? 0 or 1? True or false? Somebody used that before?
 
"All my prefab char have the age of 1,2,3,4,5,6...., which is the best and more stable way for me to identify them during the game and change my dialogues/endings/events according to the character actually used. Can be very powerfull if you want your mod to be played by a human, a ghoul and a supermutant, for example, and want them to appear at three different starting points. You can even use the age later to make the two other races enemy of the player..."

You can accomplish all this already with CVARs and few other tricks.

"There may be also a way with this method (I didn't tried it yet), to identify a custom made character (age 19 by default - no change possible because de button is invisible - or something else?)"

again all you need is Some CVARS.

"The nice thing about this method is that you then can use the TAGNAME for something else!! Use a single TAGNAME for all characters to identify the player in any situation, such as "player". This can be very useful for many things, such as moving the player instantaneously to another mission/area as with an elevator, or moving objects close to the player, or making the main player anwser to another character after he/she spoke. When cracking BOS.EXE to make the tagname stop being ereased, you can give the character a tagname only once using the first Spawning point he will appear in! Very great!"

That hack on BOS.EXE didn't work for me, anyways you still can't identify individual squad members with that anyway so. If you give your Prefab a Tagname it will stripped after you leave the first map. If you just want to identify specific prefabs that is easy. Just make a Generic entity, and tagname it, give it no sprite, and tick non lootable... now put that entity into your prefab's inventory. For a mutant race Prefab, you make the generic item entity "mutanttag" and tagname it 'mutant', then put entity 'mutanttag' into your prefab's inventory. This generic item will appear invisible in the prefabs inventory in game. Then on your very first map you have a trigger Condition: Player has more than 0 items tagged "mutant" at anywhere zone Action: Set variable 'CVAR_MutantPlayer' to 'true' then you can you use that CVAR on all subsequent maps as an identier of your mutant prefeb for dialogue/story etc...

"I would like to use also the variable "sex" to identify the player as a male or female for dialogue purpose, but I didn't try it yet. Somebody know what value it can get, like "male" and "female"? 0 or 1? True or false? Somebody used that before?"

Yes it works... Condition: Player has more 0 sex at anywhere zone... use 0 and 1 for sex's. you need to have the player alone in a specific zone to identify his/her specific sex.
 
Wow, I must say you are very ahead of me on this. I never thought about that trick with non-lootable objects with a tagname. That is just perfect. With this method, if I understand well, you can assign as many stable tags to a char as you like, you can identify any player present in your squad, not just the main char, and even make your other party member talk by themselves if they have a stable tagname and are in the right zone! They just nees a non-lootable object with a tag.

But Do these objects take a square space in the scrolling inventory or not? Do they stay in the inventory permanently?

I think I will have some conversion to make in my mod to this system of yours.
 
As I already said, these tag items 'are invisible in game' that means no they don't take a square space in scrolling inventory. They stay in the inventory permanently, unless you use the 'Give item to NPC' trigger.
 
So, there is even little use of CVar most of the time then, if you want to be notified efficiently when a char is not in the squad at a particular moment or dead. Really, a trick to recommend to everyone! I wish this is or will be in tutorial webpages somehere!
 
The unlootable tagname item method is cool, but it has limitations too. It can't identify if a specific squad member has died or not, only if he/she is on the map at a specific place. I don't know if you ever seen my old thread on DAC about this tecnique. We talked about all the possibilities with this system. Check DAC thread called 'Work around for squaddie tagnames' by xkcon
 
Yeah nice post! I never read it no. I like the part about an invisible "stitch" speaker. That could come in handy, or even M. Handy. Funny to realise you worked that out years ago :P definetly need to make a lot more tests, and try to find an easy way to detect dead squad members with precision. If cracking bos.exe to make the tagnames stop ereasing works with other squadmembers, then it will not be a problem anymore!
 
Back
Top