Bully-Board
Bully Modding Section => Bully Modding => Bully Modding Archives => Topic started by: AlphaTech on February 03, 2016, 10:08:43 PM
-
Well I have some good news now that i'd like to share. I am getting my old PC and going to try and see if I can get my old 200GB hard drive to work.
If I end up doing so I may be adle to return to modding fully becauds I have my original files saved to it. If not then I am going to just create some new mods eventually. It will take about until the end of the month though I am on vacation in Cali until March with my GF.
So hopefully when I get back everything works out good and I can finally fix the HDD. I have my laptop but can't really pay attention to modding.
What the no HDD fix means is I have to make the Zombie Mod and Pete's Missing from scratch again which will be horrible.
-
Let me guess..... Strafe mods?
-
I lost my LUA folder :(
-
I lost my LUA folder :(
See its the samething with me I lost all my lua files and may have to make all mods from scratch.
-
This is why you should try to back things up to disc when you can.
I myself hate having to start all over...but if it is with something that I know a lot about...then it is not really that big a deal to me. I just consider it a chance to improve my skills and knowledge a little bit and try to do things better.
and @ AlphaTech..
What kind of hdd problem did/are you having that caused the problem for you? I have a lot of years experience with data recovery on bad hdd's and might be able to lend you a hand or at least tell you what to do if you want to recover your data. I know just about every dirty trick in the trade when it comes to that and am also very familiar with forensic recovery too. If you want any tips....fire off an pm and I can try to assist.
-
If you do end up losing your files, don't see it as a drawback but instead, a chance to improve. Now that you have already made a lot of the script and have a lot of the ideas done, you can probably do a significantly better job rewriting it with everything you did in the past script in mind. I personally feel amazingly accomplished when I make a script where everything is beautifully designed and flows together perfectly, and usually to achieve that I end up having to rewrite it once or twice to really perfect it.
If you try hard enough and stay focused I'm sure you can get them back to where they were and get 'em released. I'm looking forward to seeing them, I'm always happy when I see some new creative mod being worked on or released for this game.
If you're afraid of losing some of the notes you may of had, check out some parts of the board's many tutorials and documentation topics.
-
I am on vacation in Cali until March with my GF.
this nigga...
-
If you do end up losing your files, don't see it as a drawback but instead, a chance to improve. Now that you have already made a lot of the script and have a lot of the ideas done, you can probably do a significantly better job rewriting it with everything you did in the past script in mind. I personally feel amazingly accomplished when I make a script where everything is beautifully designed and flows together perfectly, and usually to achieve that I end up having to rewrite it once or twice to really perfect it.
If you try hard enough and stay focused I'm sure you can get them back to where they were and get 'em released. I'm looking forward to seeing them, I'm always happy when I see some new creative mod being worked on or released for this game.
If you're afraid of losing some of the notes you may of had, check out some parts of the board's many tutorials and documentation topics.
I lost my template (my own template I am comfortable with), my action nodes, and I can't get your "Auto Compiler" working.
-
I lost my template (my own template I am comfortable with), my action nodes, and I can't get your "Auto Compiler" working.
Template for what?
Check out the lua nodes (http://www.bully-board.com/index.php?topic=22045.0) topic.
The auto compiler is simply a combination of 3 things. MadmaN's IMG toolkit (http://www.bully-board.com/index.php?action=downloads;sa=view;down=159), MadmaN/Fred Tetra's LUA compiler for Bully (http://www.bully-board.com/index.php?action=downloads;sa=view;down=60), and a simple batch file (https://en.wikipedia.org/wiki/Batch_file) that used the IMG toolkit and compiler. A batch file basically just automates whatever you'd normally do manually in a command prompt.
-
I lost my template (my own template I am comfortable with), my action nodes, and I can't get your "Auto Compiler" working.
Template for what?
Check out the lua nodes (http://www.bully-board.com/index.php?topic=22045.0) topic.
The auto compiler is simply a combination of 3 things. MadmaN's IMG toolkit (http://www.bully-board.com/index.php?action=downloads;sa=view;down=159), MadmaN/Fred Tetra's LUA compiler for Bully (http://www.bully-board.com/index.php?action=downloads;sa=view;down=60), and a simple batch file (https://en.wikipedia.org/wiki/Batch_file) that used the IMG toolkit and compiler. A batch file basically just automates whatever you'd normally do manually in a command prompt.
TEMPLATE FOR MY MODS. My nodes are beyond the stuff posted there. I can't get them back ever again. I uninstalled b bully awhile ago and lost everything.
-
I am on vacation in Cali until March with my GF.
this nigga...
(http://images5.fanpop.com/image/answers/349000/349156_1329020520805_450_300.jpg)
-
TEMPLATE FOR MY MODS. My nodes are beyond the stuff posted there. I can't get them back ever again. I uninstalled b bully awhile ago and lost everything.
Oh well that sucks. You got them before though, so why can't you get them again?
Template for what mods? You're not being very specific. Do you mean just a simple template with an empty MissionSetup, MissionCleanup, and main? That's not very hard to setup... don't panic.
-
TEMPLATE FOR MY MODS. My nodes are beyond the stuff posted there. I can't get them back ever again. I uninstalled b bully awhile ago and lost everything.
Oh well that sucks. You got them before though, so why can't you get them again?
Template for what mods? You're not being very specific. Do you mean just a simple template with an empty MissionSetup, MissionCleanup, and main? That's not very hard to setup... don't panic.
Template for style mods, mission mods that I find easy to work with.
-
Templates like that are really only good for when you're new. I think you'd benefit from making them yourself so you can truly understand all parts of the script and how they work, and so you don't have to rely on templates. It shouldn't be a problem considering style mods aren't usually that complex and mission mods can be extremely different every time so you can't really have a huge template.
-
I do understand all parts of the script. BUT THAT TEMPLATE IS FOR MY STYLE MODS, it's gonna take forever to make another template and I lost all my nodes as well :/
Guess I'll focus on missions but this community is so inactive, even if I show something, it seems awkward.
-
It's only temporary inactivity it'll start back up soon enough if you notice the guess count it is still active.
-
I don't see why you even need a template. You need a while loop, a few if statements, and a few calls to PedSetActionNode. Unless you do something really fancy...
Is popularity all you mod for? Inactivity shouldn't be a concern, do it for yourself and the people that are active, we'll appreciate it and give ya feedback. It might not be a huge community, but I kind of like it like that. You get to know everybody better and it really feels like a community, and if you release a mod, sure it won't feel like a huge release 1000s are going to see, but you're sharing it with ya homiez on BB and that should feel nice. Workin' together n' shit.
-
(what daboss said)
but yeah u dont need all the ImportScripts at the beginning of the script. and the most useless thing that i always see is that SObjTest.lua and SZone shit on the top.
if you really wanna import something, like a separate mod file, you'd do it in a function, cause i discovered that when i tried using the importscript out of a function it won't work.
function MissionSetup()
AreaTransitionXYZ(270, -110, 6)
PlayerSetHealth(PedGetMaxHealth(gPlayer))
end
function MissionCleanup()
collectgarbage()
end
function main()
while true do
Wait(0)
end
end
and u can also add the function to load all animation groups, Boss has a thread posted regarding that.
-
^ Looks like a pretty solid setup but remember the area code when calling AreaTransitionXYZ.
About that ImportScript not working outside of a function, that actually sounds pretty strange. Based on my observations and knowledge of LUA, this is how everything works. Each running script gets its own little address space in Bully, and that script can't access variables from other scripts with a few exceptions such as gPlayer and the shared table (basically a table all scripts have access to, used for sharing variables). When ImportScript is called, it simply runs a script in the address space of the script that the function was called from. So if that script had functions or variables in it, they would be in your script's address space by the time the script finished running. Now you may be saying "but boss, those scripts can't run, they don't even have a main function!" and I could see why you'd think this, but in fact the main function isn't actually a normal thing in LUA, it's just something Bully does (and probably other games do too, but not LUA itself). This is how a LUA script will run (in order):
1) The entire script will be read top to bottom executing any instructions as it goes along, such as creating variables, tables, functions, calling functions, anything like that. When the script comes across a function declaration (like function MissionSetup() ... end or MissionSetup = function() ... end) it simply puts the function in memory and has that variable (in this example, "MissionSetup") reference it. Same essentially goes with tables having variables reference them but that's a different discussion. If you want one of your created functions to run, you could call them yourself and they'd run perfectly fine. Unless you do call a function yourself, no functions have run yet.
2) Now that the script has run and all functions are loaded and such, it is time for Bully to call some functions in your script. If it is a mission script (like ArcRace1.lur), Bully will call MissionSetup first, then main, and MissionCleanup when the mission is done (success or fail). If its just a normal script (like STimeCycle.lur), only main will be called. If the script is being imported (through ImportScript) then Bully will not call any functions (but of course any functions the script itself calls will run), the script will just run through normally, and since most scripts are structured in a way that mostly functions are the only thing in the outer level of the script (like nothing else is outside of any functions), then this will usually just load the functions from a certain script (but of course still run any code in the script that isn't in any function, unless of course that function is called).
So really I don't see any reason why ImportScript wouldn't work for you, it is still a part of your script and in theory should be executed.
-
remember the area code when calling AreaTransitionXYZ.
shit it's been a while i probably suck now lol
-
Importscript works for me you can check in my Petes Missing mod and see it run the other .lur inside the scripts.img and dir. I usually see this as overwritting a script without delay or crashes.
Importscript("BossHealth.lua")
ImportScript("Ped Spawns.lua")
ImportScript("BossStyles.lua")
ImportScript("Animations.lua")
ImportScript("FailValue.lua")
ImportScript("WinValue.lua")
Some imports that I did in the past worked perfectly.
-
^What boss said. You shouldn't mod for fame or anything.
-
Importscript works for me you can check in my Petes Missing mod and see it run the other .lur inside the scripts.img and dir. I usually see this as overwritting a script without delay or crashes. Importscript("BossHealth.lua")
ImportScript("Ped Spawns.lua")
ImportScript("BossStyles.lua")
ImportScript("Animations.lua")
ImportScript("FailValue.lua")
ImportScript("WinValue.lua")
Some imports that I did in the past worked perfectly.
Is it out of a function?
-
Remember LUA is case sensitive guys. ImportScript and Importscript are two different things. Make sure to ImportScript.
Also remember ImportScript expects the name of the compiled .lur file, but with a .lua extension. For example if you have "my mod.lua" and you compile to "mod001.lur" and you want to import it, you should do ImportScript("mod001.lua").
-
Remember LUA is case sensitive guys. ImportScript and Importscript are two different things. Make sure to ImportScript.
Also remember ImportScript expects the name of the compiled .lur file, but with a .lua extension. For example if you have "my mod.lua" and you compile to "mod001.lur" and you want to import it, you should do ImportScript("mod001.lua").
Obviously it didn't take me two seconds to figure that out. Another way to setup a better running mission is to seperate its scripts. I noticed that combining plenty scripts at once can make it harder for you to fix an error ingame. "The name of the files I am speaking of."
Once I was doing a test mission to see if I could force the game to start a mini game. I made a little zombie hoard where it starts at 6 then so on and so fourth.
I noticed when jumbling everything it would always glitch and freeze somewhere but when seperating them it usually fixed this. So every round I did 6+ zombies plus a round which after round 24 it crashes.
What I did was use ImportScript to get spawn values each time 6 peds get knocked out. This is a good way to create mini games or want a mission where 24+ characters are coming at you. What I noticed though is that after 40+ spawns the game starts to lock peds off targets sometimes attack each other lol the game gets crazy.
One thing though when creating a table or kill table how would a set the ped values?
Would it be
if AllPedsDead(zombies) and MiniGame = true then
Minigame = false
end
So the value for zombies would what? If I could explain better lets say. How would I let the game know the value of ped knockouts without writing a bunch of script.
I wrote over 24 pedisdead when I did that minigame what is the easier way lol.
-
Remember LUA is case sensitive guys. ImportScript and Importscript are two different things. Make sure to ImportScript.
Also remember ImportScript expects the name of the compiled .lur file, but with a .lua extension. For example if you have "my mod.lua" and you compile to "mod001.lur" and you want to import it, you should do ImportScript("mod001.lua").
(WTF WHEN I CLICKED QUOTE I SAW AN ORANGE TAB APPEAR SAYING "LOADING" IN ORANGE LETTERS)
Wtf dude that's weird. I've always thought ImportScript("my mod.lua") would work. not really understanding how the function works. I know what it does and how it's used, but I mean like how it would be made or something.
-
ImportScript simply runs a script in another script's address space (the one that called ImportScript). So any variables (or functions) created in that script that you "imported" (technically ran) will be available to the script that imported it. If this doesn't make sense remember that functions are indeed created like any other variable. If you try to use the function somewhere in the script before it was created, then it will not work. This isn't to say a function has to be created above the code where you use it (like in C), but it simply means the part of the script that defines the function has to run before using it, which is usually done fine since first the whole script runs, putting all functions and everything outside of other functions into memory, THEN main runs (since Bully calls main after the script runs as I just explained), so you can call whatever function you want in main and it'll work fine (well assuming the function was in global scope, as in not in another function or something like that, since the function it is in may not of run).
I may be rambling a bit but it is nice to be able to understand this. A function is just like any other variable in LUA.
-- Trying to print the variable 'x' will not work as x wasn't created yet
TextPrintString("X: "..x,1,1)
x = 1
function runMyFunc()
-- Since 'runMyFunc' is called after 'myFunc' was created, 'myFunc' should be in memory and can be called
myFunc()
end
-- Trying to print the function 'myFunc' will not work as 'myFunc' wasn't created yet
myFunc()
function myFunc()
TextPrintString("my func",1,1)
end
runMyFunc()
It actually gets slightly more complex then that but, those basics are what is important in this situation. So really to answer your question as clearly as possible.
-- script.lua (compiled to myscript.lur)
function x()
TextPrintString("x called",1,1)
end
TextPrintString("imported",1,1)
-- arcrace1.lua (compiled to ArcRace1.lur)
ImportScript("myscript.lua")
When the script gets to that ImportScript("myscript.lua") (which is immediately since it has nothing else), that myscript.lur runs, and that function x is put into memory for ArcRace1.lur to use, and "imported" is printed (because remember the script just simply runs, the functions aren't all just pulled out).
-
.dude my brain is having an unpleasant orgasm after reading this.
-
Well I am about to come back from my trip so i'll get back to modding. I won't be using my desktop though it has some errors with the windows which wont let me log in. I tried everything from getting a new version of windows 7 64 bit installed to a new HDD but it just wont work anymore. Something is up with the hardware and software which a 1TB RPM HDD wont install a new version of windows. It keeps saying "error windows not installed restarting". Maybe I just need a whole new HDD port in general but that's gonna take a while.
-
I will stillt finish helping you with that....and I apologise for having been silent via pm about this as I have been....busy.
I will upload something that should help you fix the issue and failing that...all you have to do is just get an external adaptor to hook that drive straight to your laptop via usb and rip your files off of it that way.
I should have things uploaded and sent to you in a few days....just been bogged down lately and playing catchup is ..... wearing me out.