Bully-Board
Bully Modding Section => Bully Modding => Bully Modding Archives => Topic started by: AfterLife on June 22, 2015, 12:16:34 AM
-
This topic is for LUA modders, what is the first ever code taught to you? For me it was PlayerSwapModel. Taught to me by jedijosh.
What about yours (If you can remember.).
-
Honestly I can't remember. Codes have been sent back and fourth between me and my contacts. I know its not a bully function, but the first lua function taught to me was table.insert from DaBoss. Most other things I learned either from Hex Editong the Scripts, or just the few tutorials we had at the time.
-
Honestly I can't remember. Codes have been sent back and fourth between me and my contacts. I know its not a bully function, but the first lua function taught to me was table.insert from DaBoss. Most other things I learned either from Hex Editong the Scripts, or just the few tutorials we had at the time.
I meant bully related codes.
-
The first Bully LUA code taught to me was in SWEGTA's bodyguard tutorial, then the second thing I learned was setting fighting styles in LUA (also thanks to SWEGTA). Then I learned some basics about LUA as a language with some youtube tutorials and then mostly taught myself new things by experimentation with function names I found in the game's executable.
-
well the first bully related code i learned then was PedSetHealth. I don't know how, but at the time, that was the best discovery every in my mind xD.
-
I think it was TextPrintString
-
PedCreateXYZ
-
TextPrintString :D
-
The very first I learned was PedSedSetTypeToAttitude, PedMoveToXYZ, and PedClimbLadder. Those were my very first codes that I learned making the ped have agression and to make them move was amazing. I made the peds move up ladders a little later but was so happy it was my help to creating missions.
-
ExecuteActionNode and PedSetTypeToTypeAttitude.
-
PedSetActionTree
-
I was never actually 'taught' any of the bully lua coding. Tho the closest thing to being taught anything on that would be when Fred Tetra got hold of me here via pm and sent me what he had at the time on the lua scripts he was able to decompile.
Far as being 'taught' lua....even tho this actually has nothing to do with bully...that would happen to be:
require("INC_Class.lua")
--===========================
cAnimal=setclass("Animal")
function cAnimal.methods:init(action, cutename)
self.superaction = action
self.supercutename = cutename
end
--==========================
cTiger=setclass("Tiger", cAnimal)
function cTiger.methods:init(cutename)
self:init_super("HUNT (Tiger)", "Zoo Animal (Tiger)")
self.action = "ROAR FOR ME!!"
self.cutename = cutename
end
--==========================
Tiger1 = cAnimal:new("HUNT", "Zoo Animal")
Tiger2 = cTiger:new("Mr Grumpy")
Tiger3 = cTiger:new("Mr Hungry")
print("CLASSNAME FOR TIGER1 = ", Tiger1:classname())
print("CLASSNAME FOR TIGER2 = ", Tiger2:classname())
print("CLASSNAME FOR TIGER3 = ", Tiger3:classname())
print("===============")
print("SUPER ACTION",Tiger1.superaction)
print("SUPER CUTENAME",Tiger1.supercutename)
print("ACTION ",Tiger1.action)
print("CUTENAME",Tiger1.cutename)
print("===============")
print("SUPER ACTION",Tiger2.superaction)
print("SUPER CUTENAME",Tiger2.supercutename)
print("ACTION ",Tiger2.action)
print("CUTENAME",Tiger2.cutename)
print("===============")
print("SUPER ACTION",Tiger3.superaction)
print("SUPER CUTENAME",Tiger3.supercutename)
print("ACTION ",Tiger3.action)
print("CUTENAME",Tiger3.cutename)
Which was when I first started learning lua by itself. The above code is a classes and methods example. :biggrin: