[Mod] ET: Search&Destroy


(aowblacky) #1

Hi.

I would love to have a Search&Destroy mod for ET!!!

But I can’t code my own mod :smiley: - So is there any coder wich is interested in making this mod?
I already created some search&destroy maps!


or can someone give me some nice tutorials on how to make a mod?

Thanks:D


(Micha) #2

The best way to start with modding is to download etpub or noquarter source.
https://www.assembla.com/code/etpub/subversion/nodes

I think the most stuff could me made with map editing.


(WuTangH) #3

I dont know all functions of S&D mod, but if you make map with 1 dynamitable obj for a team, then it becomes S&D map, no? :o


(Micha) #4

True, he could make two objects and call it spot A and B. Then end round if one gets destroyed.

Set spawntime 999.
Rest could be made with lua (like scripting the last person allive wins for his team).


(Mateos) #5

There’s a limited lives thingy in ET already, enable it to 1.


(aowblacky) #6

not rly. S&D is more than just 2 destroyable objectives.


(twt_thunder) #7

Then give us more info?


(aowblacky) #8

(Mateos) #9

Sounds like Counter-Strike x)


(twt_thunder) #10

For me it sounds like you have this in et allready, just set maxlife to1 and run an objective map?


(Nail) #11

for W:ET maps, just run LMS mode


(aowblacky) #12

its not that easy.

in S&D there is a bomb. wich can be picked up from the attacking team. and only the player with the bomb can plant the OBJ. if this player dies the bomb get’s dropped. but the bomb is not returnable by the defenders. (so if a defending player touches the bomb nothing will happen. - in ET the bomb will be returning to its default location) AND as i already said: only the player with the bomb can plant. if he drops the bomb and another attacking player takes it then this player should be able to plant.
i already tried many things to make it, but mapping alone cant do this. there is a need of a mod.

it would be awesome if:
if the attacking player takes the bomb he should get the pliers. if he drops the bomb the pliers should be removed for him too.
that way it’s easy to make the mapping-stuff because then it would be a constructible obj, and only the player with the bomb is able to construct/=plant the bomb.

is this possible? and is it possible to not return the obj if the defender is touching it?

i hope you know what i mean :slight_smile:
BlAcky


(acQu) #13

AFAIK Lua has no item_touch event. That would be the most convenient way if Lua supported that. Basically there should be possibilities, but i haven’t checked them. My approach would be to go for a full-fleged mod instead of Lua, but with Lua scripting it might be possible as well.

To be clear, here is the game-mode description:

Search and Destroy, often abbreviated as S&D or SnD, is an elimination-based game mode that has been featured throughout the Call of Duty series. A one-sided game mode, the goal is for an attacking side to either eliminate the defending team or detonate either one of two bomb sites. Players only get one life per round, with most versions of the mode going to a best-of-seven rounds (first to four rounds wins). There is an intermission/half when two or three rounds are completed.

So you need:

  1. dynamite item spawning which is carryable, should spawn in the map somewhere at map start
  2. no player should spawn with dynamite and pliers
  3. player picks up item -> player gets dynamite + pliers
  4. player dies and tabs out -> item is thrown out of his body on the nearby ground for others to pick up

I haven’t picked up Lua in ages, but here is what i would do to check if its possible with Lua:

For 1): check “G_SpawnGEntityFromSpawnVars” (http://wolfwiki.anime.net/index.php/ETPro:Lua_Mod_API#entities). You should be able to spawn in such an item at map start. If this fails, the whole approach fails.
For 2): check et_ClientSpawn (http://wolfwiki.anime.net/index.php/ETPro:Lua_Mod_API#qagame_execution). If player spawns, make sure you reset his pliers and dynamite flag. Not sure if the field is supported, but i think it is. Fields are here (http://wolfwiki.anime.net/index.php/Fieldname)
For 3): this can’t be done a normal way, you must use et_RunFrame (http://wolfwiki.anime.net/index.php/ETPro:Lua_Mod_API#qagame_execution) and on each frame check if the player picked up an item. Not sure if this is possible either, again, you must check the fields and see if you can get the info there, and then set the dynamite and plier flags.
For 4): the item should be thrown automatically. Flags should be reset by what you did in 3. If other player picks up item again, 3) should handle this as well.

Hope that helps. It could entirely be that it doesn’t work. But that is what i would check right now, if i had the time. Otherwise, i would make a mod. I am 99% certain that this is possible with a mod.


(stealth6) #14

I remember a proof of concept map by isbowthen:
http://forums.warchest.com/showthread.php/17225-new-map-shield-b1

In this map you activated a shield that followed you around, so you could use this to make a bomb that floats above your head or follows you. (then you don’t have to worry about returning it)

(Offtopic: wow talk about a walk down memory lane :o )

Anyway if there is a way to mark a player so only the person with the bomb can arm the dynamite, then it would be possible with just a mapscipt. (a mod would be better, but it might be possible to make the basic idea with just a mapscript)


(aowblacky) #15

[QUOTE=stealth6;469503]
Anyway if there is a way to mark a player so only the person with the bomb can arm the dynamite, then it would be possible with just a mapscipt. (a mod would be better, but it might be possible to make the basic idea with just a mapscript)[/QUOTE]

i have already tried a few thing, how would you do it?


(stealth6) #16

Well in the map I posted you could pick up a shield carry it around and drop it anywhere, so that solves a lot of problems you have with your bomb. It also uses a trigger multiple so you could limit it to 1 team.

The only thing I don’t know is how to detect if the person carrying bomb is near the objective. Then you could just require that person to stand still for X amount of seconds to arm the bomb. Maybe somebody can say if that is possible or not? (a mod would probably be easier :tongue:)


(aowblacky) #17

lol, downloaded it, decompiled it.
trigger maze haha :smiley:


(Destroy666) #18

Maybe something like this - spawn anywhere this set: 2 team activated triggers with 2 attached stealable invisible bombs, one for each team. After activating one trigger hide both immediately and attach them and enemy stealable bomb to player, set the other one visible so it’s stolen. If the player got killed, in the dropped event set the triggers visible again and hide both bombs.

In the place where bomb should be placed make a capture point. After capturing obj, set a constructible bomb visible and place another set of 2 triggers and bombs (but only defending team trigger visible) so they can steal it back before it’s fused.

If it was fused, set the another set invisible and place constructible for defenders so they can defuse it. Wait xxxxx miliseconds and end map if they didn’t. If they managed to construct it, set the another set of 2 triggers and bombs + attackers constructible visible again. If the set is stolen by defenders, set the attackers’ constructible invisible. And so on…

Not sure if possible to attach triggers/bombs like that (based on the shield I guess it is) and if the objectives would stay in place (no autosecure) while being invisible, it’s just a clunky concept which could theoretically work.


(xdjenkins) #19

Considering you’d do a special set of maps for your mod… And as long as I understood the concept of the mod correctly…

From the perspective of the coder, I haven’t really looked at the events related to objective pickup but I am sure it must be possible and probably relatively not hard to implement a simple check on if objective is picked up by player (if it isn’t already here that is).

Now if the first point is doable the rest of points in what seems to be simpliest way IMO is about adding a set of pliers and dynamite to every class at the spawn, modifying the functions related to weapon selection to not allow to equip dynamite and/or pliers unless player is holding objective, on objective pickup - force player to hold dynamite or pliers and modify functions related to weapon switching to not allow player to switch to something else than dynamite/pliers. And… that sounds like it? ETPub already had an option somewhere to allow objective throwing when equipped with knife. I am sure it’s possible to change the times at which objective is taken back to the spawn-point too…

Just a little concept. If I ever have time I will try to write some code for it but I am currently busy helping Thunder on his mod and also developing a theme for it’s website…


(ailmanki) #20

You could use the existing objectives with a bit of lua.

Afaik lua does not know about objective pikcup or drop. But you can scan for msg’s.
So if you know player X has taken the objective, he is the guy with the bomb.
Once he dies, remove the objective, and place with lua a new objective there. Maybe a mix between mapscript and lua is needed for that to work properly. If the objective can’t be created with lua, then you will need a dummy objective which you can move around by lua…

Now, I don’t know how the bombsite should be handled. Can the defenders defuse the dyna? Or is it just deliver and boom?
In any case, this could be solveable without any lua at all.