Apocalypse87 0 Posted December 29, 2001 I am new to map making, but slowly learning and i need some help with a CTF map I am making its Rus. vs. NATO each side has one transport chopper (No Ammo) and i need them both to respawn after a while, now your thinking just go to the editing center, hehehe, well yes i have been there, first i tryed the tutorial by NovaPhoneix since it didnt seem to hard to place on my map anyway it worked but i had problems with it, my heli would lose 60% of its armour after it got hit then it would automatically repair itself and respawn while i was flying in it, other times it would get destroyed repair itself and not respawn to its orignal starting location for a while so people could get in it and fly it before it even respawned, so i gave up on that, i then used the tutorial by DeaDMeaT in the code snippets section at the editing center, this was alot more advanced for me and i didnt know how to get it working on my map. So all i need is someone to maybe give me another site (tutorial) that will help me to get my heli's respawning or if someone could help me or make a code for me to get my two choppers named heli1 and heli2 to respawn .... please Share this post Link to post Share on other sites
HellToupee 0 Posted December 29, 2001 you need a script just look round the editing sites for one they have instructions on how to use them. Share this post Link to post Share on other sites
CanisDEK 1 Posted December 29, 2001 It's really not that hard. You need to use the new deletevehicle and createvehicle in a script called by the initialization field of the vehicle you want to respawn. ********************************* IN EDITOR: 1) make a "game logic" called respawn1 2) make a "game logic" called server 3) make a vehicle - no name needed but write this in the initialization field: [unitName, Location, Azimut, VehicleClass] exec "VR.sqs" Unitname = name of vehicle or just <this> (without <>) Location = Respawn1 Azimut = facing or <Random(360)> for random (no <>) Vehicleclass = "UH60MG" or "OH58" (WITH THE " ") exec "VR.sqs" = execute script called VR.sqs with variables between the [ ] Example: [this, respawn1, random(360), "UH60MG"] exec "VR.sqs" ***************** IN SCRIPT: make a script called VR.sqs (use notepad and save as VR.sqs - everything in { } is explanation and should not be in the script. lines starting with ; will not be executed. ;THE SCRIPT called VR.sqs ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ;Variables found----> ; ?!(local Server): Goto "end" {if computer isn't server end} _vcl = _this select 0 {select the variable unitname} _Location = _this select 1 {select respawn1 or whatever} _azimut = _this select 2 {select facing variable} _class = _this select 3 {select class variable} _respawndelay = 30 {the time it takes to respawn} ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ;Respawn script, vehicle deleted and created if not alive ; #start ~1 ?(Alive _vcl):Goto "start" {if vehicle alive then loop back} ~_respawndelay {the delay in secs set earlier} _vcl setdammage 0.2 {otherwise smoke will stay too long} deleteVehicle _vcl _vcl = _class createVehicle getpos _Location _vcl setdir _azimut Goto "start" #end Exit ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; *********************** Well that's it. PS: I would like to thank the OFP Editing Center and especially: Backoff, OFP Editing Moderator, OFP Editing Veteran for helping me figuring this out. Sign up at the OFP Editing Center you'll find answers for most of your questions at their forums! http://www.ofpeditingcenter.com/Default.asp (Edited by CanisDEK at 5:08 am on Dec. 29, 2001) Share this post Link to post Share on other sites
CanisDEK 1 Posted December 29, 2001 Oh and if someone finds a complete list of vehicle names used by the editor please tell Share this post Link to post Share on other sites
Rob 1 Posted December 29, 2001 Didn't BIS make a new manual? and it gave a very simple explination on how to respawn units? Share this post Link to post Share on other sites
CanisDEK 1 Posted December 29, 2001 This is the very simple explanation... if you look at the script and the things to do in the editor there isn't much to it actually. Share this post Link to post Share on other sites
uddercream 1 Posted December 29, 2001 canis i tryed your script and it didnt work hmmmm... Share this post Link to post Share on other sites
CanisDEK 1 Posted December 29, 2001 it didn't? well if you private message me your ICQ number I'll send you the script plus a mission example... I use it in all my missions and it works fine. Perhaps you made a typo in the script or perhaps I did ... anyway message me and I'll send it to you Share this post Link to post Share on other sites
CanisDEK 1 Posted December 29, 2001 Or you could just get it at the OFP Editing Centre. I posted the example mission there as a file attachment. Remember to thank Backoff as it was him who figured out how to use the two new commands http://www.ofpeditingcenter.com/cgi-bin/YaBB/YaBB.pl?board=board_multiplayer&action=display&num=1009660047 Share this post Link to post Share on other sites
Apocalypse87 0 Posted December 29, 2001 ok with the help of both scripts i got the heli respawning ... now for the trouble ... I want my helis to respawn with NO ammo is this possible if it isnt then i'll just have to give Ruskies a UH60-MG Share this post Link to post Share on other sites
CanisDEK 1 Posted December 30, 2001 Well Apocalypse I got disconnected from the chat because my squad.xml crashed the server Anyway I think the three CTF missions I have done with t´his new respawn is the same as you want to do. Give each side a transport heli only with a MG. I gave both teams a CH47D because I like them, but it's annoying that the russian CH47D belongs to the Western side. I think BIS should include a transport heli for the russians like the UH60MG or CH47D... that would help us alot I tried messing with the "side Rus_heli==east" thing but frankly I haven't really been succesful. I think the command is reserved for soldiers. If this or another command could be used we could just make two respawn scripts: VR-Rus.sqs and VR-US.sqs where the side is set for the heli each time it is respawned. Hmmm if you come up with something please tell me Right now I have to decide between two annoying options: 1) CH47Ds for both sides making the russian one US friendly, which is bad. 2) Using Mi17 for russians where I have to make a new script where each vehicle type is taken into consideration if it is to be universal... Besides the two helis are too different to make the game fair Share this post Link to post Share on other sites
EmperorVader 0 Posted January 10, 2002 could some one send me a sample plz? Share this post Link to post Share on other sites