Using Turret plugin

Questions and answers about the how and why of making maps.
Post Reply
User avatar
Agent West
Private First Class
Private First Class
Posts: 318
Joined: Thu Jan 31, 2008 1:32 pm

Using Turret plugin

Post by Agent West » Fri Aug 02, 2013 1:52 am

Hi
I'm working on a map and would like to include couple turrets in there. Following the "readme" file from the plug-in this was created:

options
-loadplugin pass\to\plugin\Turret,1
end

#--Turrets---------------------------------------

turretWeapon
name turret1
position 267.43 267.43 156
type MG
lifetime 1
frequency 1
tiltExtent 0 90
angleExtent 0 360
end

turretZone
name zone
position 267.43 267.43 156.59
size 4 4 1
rotaton 45
addWeapon turret1
end

box
name blue_turret
position 267.43 267.43 156.9
size 4 4 0.9
matref blue_team_glass
shootthrough
end
box
name red_turret
position -267.43 -267.43 156.9
size 4 4 0.9
matref red_team_glass
shootthrough
end

turretEjector
position -6 0 0
size 3 3 1
addZone zone
end


(Where "pass\to\plugin" is location of file) Now the map will not load, and an error saying "Unknown object 'turretWeapon'" is displayed. What is causing that?
Rest in peace, AliceD (AKA Happy Alice)! miss ya!

User avatar
blast
General
General
Posts: 4732
Joined: Fri Mar 21, 2003 3:49 pm
Location: playing.cxx
Contact:

Re: Using Turret plugin

Post by blast » Fri Aug 02, 2013 3:13 am

Try loading the plugin outside of the world file (and possibly before the -world option in the configuration - that part might not matter, though).
"In addition to knowing the secrets of the Universe, I can assure you that I am also quite potty trained." -Koenma (Yu Yu Hakusho)

Image

User avatar
Agent West
Private First Class
Private First Class
Posts: 318
Joined: Thu Jan 31, 2008 1:32 pm

Re: Using Turret plugin

Post by Agent West » Fri Aug 02, 2013 4:28 am

Moved the whole "options" block before "world" block and moved -loadplugin to be the first thing, still same error. What do you mean "outside of the world"? Through a different text file that basically tells the program what to start when? Or as a stand-alone program that BZFlag can use as needed?
Rest in peace, AliceD (AKA Happy Alice)! miss ya!

mr64bit
Private First Class
Private First Class
Posts: 89
Joined: Fri May 06, 2011 4:58 pm
Location: Hang on, let me get a map...
Contact:

Re: Using Turret plugin

Post by mr64bit » Fri Aug 02, 2013 12:54 pm

Have it as a argument when you start bzfs. instead of

Code: Select all

bzfs -world turretmap.bzw
remove the line in your world file that loads the plugin, then start it like this:

Code: Select all

bzfs -loadplugin pass\to\plugin\Turret,1 -world turrenmap.bzw
---mr64bit

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests