Can anyone create a Throwing Knife script?
#11
This game has throwing knives: http://buildism.net/games/Tool-test/2040

Also, the Heights property of Terrain might be useful for making a generator... I'll make a demo game that uses it.

Edit: Here it is: http://buildism.net/games/Terrain-Genera...ample/6087

Script:
[lua]
link(game.Players.ChildAdded, function(p)
local size = game.World.Size.x/2
gameConfusedcheduleTask(function()
game.Storage.Buttons:clone().Parent = p.UI
local b = p.UI.Buttons
link(b.Chaotic.MouseDown, function()
local h = {}
for i=1, size do
h[i] = math.random(10, 30)
end
game.Terrain.Heights = table.concat(h, ",")
end)
link(b.Flat.MouseDown, function()
local h = {}
for i=1, size do
h[i] = 20
end
game.Terrain.Heights = table.concat(h, ",")
end)
link(b.Sloped.MouseDown, function()
local h = {}
for i=1, size do
h[i] = (i/size)*20+10
end
game.Terrain.Heights = table.concat(h, ",")
end)
end)
end)[/lua]
Reply
#12
Interwebs do you think you can make the knife texture?
Hello
Reply
#13
[Image: 33zfc0o.png]
Not my best sprite, but people are gonna be throwing these.
[Image: 76561198037039305.png]
[Image: nmdd7o.gif]
Reply
#14
Hmm, the leaderboard buttons seem a bit "cut off":

[Image: 35n9g20.png]

Any way you could make them a bit smaller so that there's enough space around the edges for it to be whole?
More work done on the leaderboard now. I have a function that automatically generates it (for when the player joins) and I have one that makes the stat directory for the player (again, when joining). Things I still need to work on are updating the UI when stats change, making the UI off-screen by default and adding a button that pulls it up temporarily, and maybe make it alphabetize the list of players or remove the players' stats when they leave the server -- I'm not sure about those.
Reply
#15
Your throwing knife, is done.

Oh btw, everyone, if you want a preview on what she's gonna do with these...



Attached Files
.bsmodel   Throwing Knife.bsmodel (Size: 2.3 KB / Downloads: 5)
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)