FAQ  •  Register  •  Login

Curve tool

<<

Whittling While

User avatar

Posts: 235

Joined: Wed Apr 07, 2010 10:22 am

Location: Minnesota

Post Thu Feb 10, 2011 4:18 pm

Curve tool

Will this ever be an implement in the actual Level Editor? When it was released for Zap! I remember it being a PC oriented tool only, which meant Mac users never could use it.
Premier Cloaker
"Time is an illusion; lunchtime, dually so."
<<

watusimoto

Site Admin

Posts: 1558

Joined: Tue Feb 23, 2010 7:07 pm

Location: Quartz's mom's house

Post Thu Feb 10, 2011 5:43 pm

Re: Curve tool

Well, I'm not planning on implementing it; however there is now a way to run lua scripts from the editor to create items that are then inserted into the editor. If there were others out there who wanted such a thing, it would be easy enough to create. Basically, the script would just need to generate the equivalent of a line from a level file that had the shape you wanted.

If anyone wants to write such a tool, I'm willing to help with getting you started in terms of how to run the script, where to put it, and so on. Note that this would also work on all platforms.

It should be pretty easy.
<<

karamazovapy

Posts: 1567

Joined: Tue Feb 23, 2010 7:52 pm

Post Thu Feb 10, 2011 5:58 pm

Re: Curve tool

I wrote a Lua script that would create curves using variables set right at the top of the file, pretty similar to a script-version of the curve tool. I kind of got bored with cleaning it up, though. It's probably mothballed on my harddrive.

Sam could probably crank out a really pretty version in about 10 minutes, though.
<<

watusimoto

Site Admin

Posts: 1558

Joined: Tue Feb 23, 2010 7:07 pm

Location: Quartz's mom's house

Post Thu Feb 10, 2011 6:07 pm

Re: Curve tool

Just an example of how easy it would be:

  Code:
local p1x = arg[1] or 0
local p1y = arg[2] or 0
local p2x = arg[3] or 1
local p2y = arg[4] or 1

local pts = { Point(p1x, p1y), Point(p2x, p2y) }
local wallsize = 20
levelgen:addWall(wallsize, false, pts)


Copy this into a file called "line.lua" in your levels folder. In the editor, open the console by pressing "/", then type

run line.lua

(the .lua might be optional). It will create a line from (0,0) to (1,1). If you type

run line.lua 1 1 2 1

you'll get a line from (1,1) to (2,1)

So now you know how to run a script from the editor; how to pass params to it; and how to insert walls back into the editor. All you need is the geometry calculations and a little basic Lua info, which is easily available on the web.
<<

ZoombeR

Posts: 1036

Joined: Fri Jun 04, 2010 11:56 pm

Post Tue Jul 26, 2011 11:59 am

Re: Curve tool

ShadowX.loner wrote:Will this ever be an implement in the actual Level Editor? When it was released for Zap! I remember it being a PC oriented tool only, which meant Mac users never could use it.


get darwine for mac. It will open this .exe file. I use zap curve tool alot with it.
<<

Qui

User avatar

Posts: 150

Joined: Thu Mar 11, 2010 12:44 pm

Post Tue Jul 26, 2011 1:22 pm

Re: Curve tool

Or just wine in general. http://wiki.winehq.org/MacOSX.

Darwine is a somewhat outdated package thing. There are other, more modern ones, but you can also just run things in terminal like a boss.
Qui ckRime
<<

ZoombeR

Posts: 1036

Joined: Fri Jun 04, 2010 11:56 pm

Post Tue Jul 26, 2011 5:36 pm

Re: Curve tool

Qui wrote:Or just wine in general. http://wiki.winehq.org/MacOSX.

Darwine is a somewhat outdated package thing. There are other, more modern ones, but you can also just run things in terminal like a boss.


there's mono which can run the .NET stuff too.

I have:

Crossover
Mono
Wine

They pretty much cover everything. Bitfighter runs great in Crossover too.

Return to General Map/Server

Who is online

Users browsing this forum: No registered users and 4 guests

cron