Various scripted objective issues + repeated wm_announces


(G0-Gerbil) #1

Me church map has a few problems, which simply shouldn’t exist - particularly annoying when an older version of the map doesn’t exhibit these problems (IE the script etc. all work properly).

As an example, I have an objective that is to blow a door.
Simple enough, except when it’s blown, I get the wm_announce message 4 times???

It’s more ‘interesting’ than that, though, because my alarm (used to shorten allied respawn time) is the following:

func_invisible_user -> relays -> split according to which team uses it (cos only allies can switch alarm on, only axis switch it off) -> target_script_triggers

The point being, of course, that a different script gets called depending on what team uses the button.

Now the thing is, my code IS getting called (the spawn time does change), but the alertentity functions (to visually toggle graphics to show alarm is on / off), as well as the togglespeaker are simply ignored (these used to work in previous version!). The final line of each function is a wm_announce (to say whether it’s just been switched on or off). This gets printed 4 times in-game :confused:

So erm… what’s the deal? I’ve checked everything I can think of, but this bug has been around for the last 3 or 4 days, and I can’t determine any difference between old (working) and new (not). Can’t go back to older version though cos of all the other changes I’ve made in the mean-time :frowning:

Help :slight_smile:


(chavo_one) #2

Gerbil, are you running the old alertentity->target_relay->func_static routine?

If so, I think ET “supports” a simpler method of setstate->script_mover. Much simpler if you are designing a new map for ET, but a bit of a pain if you are converting (I imagine).

Don’t know if I’m on target with what you are describing though. :???:


(SCDS_reyalP) #3

Do you have multiple entities with the same scriptname ?


(G0-Gerbil) #4

I checked for duplicates, but it’s a no-go :confused:
I also get duplicate messages when picking up and delivering the objective :frowning:

I’ll have a bash replacing the func_static with script_movers though, see if there’s any joy in that bit.

I just don’t understand though why it did work and now doesn’t sob

Might take a break from that and sort the icons and commands maps - leaving something for a while often allows you to come back to it from a different angle.


(G0-Gerbil) #5

OK fixed 2 of the problems.

The side door (dynamitable objective). The actual func_explosive had an errant spawnflag value (64) left over from RTCW. Deleting this fixed it.

The alarm (func_invisible_user objective). What I had before was the func_invisible_user targeted 3 target_relays. One went straight to a target_speaker (for a buttony noise). One was set to filter blue team and went to a target_script_trigger that called the alarm_on function in the alarm script object, and the other filtered red team and went to a target_script_trigger that called the alarm_off function in the alarm script object.

OK what I now have is this:

func_invisible_user targets single target_relay that targets the 3 target_relays (set up as before). Now the target_script_triggers call the alarm_on / _off functions in game_manager (all the old alarm object did was trigger these routines indirectly anyway).

It works. Not sure why…

Still have my final repeating function to get rid of when you deliver the single final objective to a trigger_flagonly_multiple to end the game, but am getting there slowly… :slight_smile:


(G0-Gerbil) #6

Delivering objective repeat was cos it was using the old RTCW method of dropping flag.
New one giving the objective a scriptname and using it’s captured / stolen /returned functions in it’s script object sorted it out :slight_smile:

Thought I’d fixed the switch stuff, but hadn’t, but HAVE now fingers crossed
No clue why, just rebuilt the whole thing from scratch in several different ways until one worked.

More complicated now though, cos I’m using two identical TOIs and toggling them on and off (and their corresponding command map markers, but that’s another bug… ;)), so now you can tell from the map screen whether the alarm is on or not \o/

So I think I’ve got all that sorted now at last :smiley:


(Thej) #7

Yay! :banana: :bump: :drink: