Posts from Scripts
Auto-translated
Good evening, I tried to create a script that would remove a hero who interacts with the Dungeon (i.e., activates the Dungeon, receives the reward, and the hero who activated the Dungeon should be removed). But, unfortunately, I couldn't make it work. If it's possible to do this, please help.
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
As an alternative, the function initiates a check that waits until the owning player has more than one hero (to prevent deletion from resulting in a loss), and then deletes the hero.
Excellent, thank you.
Hi! So, I wrote a function, added a notification in it using print, and to avoid having to stare at the green font, I decided to recolor it. So, I have this code:
function AllowHero( PLAYER, Hero )
print( "<color=yellow>Героя <color=orange>", Hero, " <color=yellow>нет на карте. Функция по его добавлению на карту работает" )I.e., in the game console, yellow text with an orange hero name Hero should be displayed, but for some reason, Hero shows up in an eye-searing green color for me. How could I fix this issue? Also, is there any way to change the console font color from green to something else? Because green is really uncomfortable for me.
Of the colors definitely available by "name" — black, blue, neutral, negative, positive, and so on, like in MlTags. And if you add \n before the string, the entire print will be white
Changing the default color in the console entirely — I think it's possible through workarounds, if, again, you find the color_positive tag in the game files and specify a different color inside it, e.g., #FFFFFF (white)...
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
try concatenating the hero's name instead of specifying it separately
I don't quite understand what you mean; I would appreciate it if you could show me an example).
Added 2 minutes later
From the colors that are definitely available based on "names" – black, blue, neutral, negative, positive, and so on, as in MlTags. And if you add \n before the string, the entire print will be white.
Changing the default color in the console – I think it might be possible through some workarounds, if, again, you can find the color tag color_positive in the game files and specify a different color inside, for example, #FFFFFF (white)...
Regarding colors: In general, I first saw this feature on the "Veil of Darkness" map by RedHeavenHero, which led me to conclude that his maps are interesting not only for their plot and landscape design but also for the interesting "behind-the-scenes" aspects.
Regarding the console color: Hmm, thank you... I need to try and see, but it seems to me that this is embedded somewhere in the game's resources, which cannot be accessed without dissecting the engine.
I'll test xdb with tags now, if it doesn't work — then indeed, only exe
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
I'll test xdb with tags now, if it doesn't work — apparently, indeed, only exe
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
I tried this script, but unfortunately, the hero is not removed. Nothing happens.
function PrisonTouch(hero)
Trigger(OBJECT_TOUCH_TRIGGER, "Prison", nil)
startThread(function(hero) pl=GetObjectOwner(hero); while not (length(GetPlayerHeroes(pl))>1) do sleep() end; RemoveObject(hero) end, hero)
end
Trigger(OBJECT_TOUCH_TRIGGER, "Prison", "PrisonTouch")I tried this script, but unfortunately, the hero is not removed.
Nothing happens.
Yes, the console doesn't show any problems. Yes, I gave the dungeon the name "Prison". But if you use the editor's console, it doesn't understand why "Length" is needed.
I haven't heard about "Twilight of Darkness"; could you provide more details?
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________