sektor2111 wrote:If it would get called a lot you could have a bunch of Fans
That's not what I meant - of course PostBeginPlay(), where in you spawn a Fan, is executed only once for every SpawnNotify (PostBeginPlay() should be executed only once for
every Actor, not only SpawnNotifies;).
Let me tell how I guess that SpawnNotifiers work: They are organized in single linked list (like Inventory or the Mutator chain), and the start anchor is
Level.SpawnNotify. A SpawnNotify
manages adding and removing from this list itself in the events PostBeginPlay() respectively Destroyed().
For every spawned Actor the engine runs through this list and checks if the spawned Actor is of the same class or a subclass of the given
ActorClass from that current SpawnNotify. If so, the function SpawnNotification() of the current SpawnNotify is called and the just spawned Actor is passed to it. With the default settings the function just returns the given Actor (line 54 is the source code).
You may now argue that you did not implement the function SpawnNotification() - nevertheless the code is executed in the parent class. Also the single linked list has one element more than needed.
sektor2111 wrote:then I must ask: Where is the load ?
Just above. Well, reducing this does not save the world nor makes the world climate better or your machine significant faster, but I may ask: Why code executing for nothing? You can have the same results by using a "normal" Actor without having more writing work and having less CPU code.
sektor2111 wrote:%K and %O are just assumptions, you have to connect them with gameinfo properly.
I have checked the corresponding GameInfo class very properly and seriously (MonsterHunt in this case) and found that %k and %o are handled there.
BTW: your native C++ code cannot be from UT: If you leave out that "%k" in UT, the message is not processed at all.
sektor2111 wrote:I dare to say that these are NOT FOR mappers.
If the map is designed for a certain GameInfo class your argument is brushed away.
sektor2111 wrote:We do need a Killer and an Other and a Weapon for Killer, else it doesn't make any sense...
The code you posted works if none, one, two or three arguments are given. It just substitutes the variables with the corresponding names and mapper can produce a senseful message.
sektor2111 wrote:Barbie wrote:But where can I set this [the ActorClass] in UnrealEd?
Perhaps is easy with EditActor command - or using another Engine having
So I guess the Epic developers have forgotten the brackets... It is definitely a variable that has to set by mappers in UnrealEd.
sektor2111 wrote:it's their [Epic developers] goofing restricting coders
Yes, I also know coders who set functions as
final for no reason.