Author Topic: Script Manager - Easy opening of scripts and SWEPS (ULX v2)  (Read 6476 times)

0 Members and 1 Guest are viewing this topic.

Offline Golden-Death

  • Hero Member
  • *****
  • Posts: 751
  • Karma: 0
  • Honored Lua Scripter
    • BlueFire
Script Manager - Easy opening of scripts and SWEPS (ULX v2)
« on: September 02, 2006, 12:42:31 PM »
This is my original script management script, just converted to ULX 2

--Updated Thread--
Something I made out of lazyness, I got tired of having to type out
lua _PlayerGiveSWEP(1,"rocketlauncher.lua") and lua_openscript emine.lua
It also eliminates the need to figure out whos playerid is whos.
So, I simplified it.

This script makes it so that if you want to give player bob: "Weapons/Golden-Death/p90.lua", you type in chat:

!gun bob golden-death/p90

Or, if you want to give a player bob: "pushstick.lua" (Not in weapons directory), type

!gun bob pushstick

Alternatively, 'ulx gun' in console.

For opening scripts, if I wanted to open script "emine.lua" I type

!script emine

and it'l open up that script. (Alternatively 'ulx open' in console) Enjoy!

http://ulyssesmod.net/gd/sm2.html



Don't include quotes, .lua, or weapons/ when giving a weapon, it is not needed

Version 3 Changes
Converted to ULX v2

Version 2 Changes
You can now give guns to teams, using !gun TEAM weapon
Teams are:
teamspectator
teamunassigned
teamred
teamblue
teamgreen
teamyellow

An example would be
!gun teamred pushstick

You can now see what options are available by using ulx_list.
This will list all the files in lua/ and lua/weapons.
You can also give it a directory, like so:
ulx_list weapons/BobsSweps
and it will list all the files in there.
You can also add directorys that are protected from listing in the top of the file. The init folder is protected by default.

To see examples, look at my post below!
« Last Edit: December 18, 2006, 07:01:10 PM by Golden-Death »