Skip to content

Posts from Scripts

4.8 (8 ratings)
User Avatar
Auto-translated
Is it possible to move a hero's castle from one location to another, or to create it when entering a certain region, just like CreateDwelling creates a building?
User Avatar
Auto-translated
How can I remove a building? For example, there's a Necropolis on the map that gives the player zombies, and I need to remove it. Usually, to remove an object from the map, like trees, creatures, or anything else, I use RemoveObject, but this script doesn't work on the Necropolis and gives an error.
User Avatar
Auto-translated
I carefully reviewed the properties of the Necropolis, but I couldn't find the IsRemovable property.
User Avatar
Auto-translated
Then you can use SetObjectPos to place it in a secluded corner of the map.
С уважением, }{0TT@6bI4
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
User Avatar
Auto-translated
Good day.
I couldn't find an example script anywhere, so I'm posting my problem here:
I need to spawn a hero from the reserve onto the map, but not at a specific point, but inside a town's garrison.
Do you have any ideas on how to do this, and is it even possible?
In reply to Лоли Никита
User Avatar
Auto-translated
Loli Nikita
How can I remove a building? For example, there's a Necropolis on the map that gives the player zombies, and I need to remove it. Usually, to remove an object from the map, like trees, creatures, or anything else, I use RemoveObject, but this script doesn't work on the Necropolis and gives an error.
You need to use RazeBuilding in this case.
Нет войне.
User Avatar
Auto-translated
I think I wrote everything correctly, but it gives an error: "Not enough arguments when calling function GetHeroCreatures" function portals()    SetObjectPosition ('Duncan',121,123,-1,4);    AddHeroCreatures("Duncan", 1, 3)  for i=1, 179 do  if GetHeroCreatures(i)>=1 then  RemoveHeroCreatures('Duncan',i);  end;  end;    end;    Trigger( OBJECT_TOUCH_TRIGGER, 'PORT_1','portals');
User Avatar
Auto-translated
function portals()
   SetObjectPosition ('Duncan',121,123,-1,4);
   AddHeroCreatures("Duncan", 1, 3)
  for i=1, 179 do
  if GetHeroCreatures('Duncan',i)>=1 then
  RemoveHeroCreatures('Duncan',i);
  end;
  end;
   end;
   Trigger( OBJECT_TOUCH_TRIGGER, 'PORT_1','portals');

The same error occurs - "Not enough arguments when calling function GetHeroCreatures".
User Avatar
Auto-translated
The GetHeroCreatures function requires only two parameters: the hero's name and the creature ID.
С уважением, }{0TT@6bI4
_________________
Группа картостроителей
Там ответы на вопросы, руководства, гайды и прочее
Discord-сервер "Герои 5: S.T.A.L.K.E.R"
Сервер по модификации "Герои 5: S.T.A.L.K.E.R"
_________________
User Avatar
Auto-translated
Could you provide a script that would rebuild the Capitol in a Castle if it was destroyed and the Castle was captured by another player?
User Avatar
Auto-translated

Hello everyone!

Please tell me how to make it so that in the battle function (when a player enters a specific area and fights creatures), it's the player's heroes (Red, Blue, Purple), and not just one specific hero, who engage in battle when entering that zone.

Statistics

Welcome our newest member: Emil