He burned his bridges, then pissed all over the ashes and smeared them up the wall.
He won't be back.
[QUOTE=CarlBooth;25556674]He burned his bridges, then pissed all over the ashes and smeared them up the wall.
He won't be back.[/QUOTE]
Shame, I was thinking about using Kari as a scripting language for my game. Oh well.
Also, do you guys think I should use Lua or Python for my game? Lua is more well known (I think) but Python has OOP.\
Eughh. The next thing on my todo list is to add 3 entities, prop_static, prop_dynamic, and ent_string, but there's no way to differentiate between prop_dynamic and static till I intergrate Box2d
Lua has OOP. I found myself saying "Lua doesn't have OOP" before, but that's not true at all. Lua has the facilities to even implement class-like OOP with metatables if you wanted.
[QUOTE=neos300;25556977]Shame, I was thinking about using Kari as a scripting language for my game. Oh well.[/QUOTE]
Not sure what him being banned from facepunch has to do with you not using Kari,
Anyway, does turb_ have like a blog or something? I'd like to see what he's up to
[QUOTE=Jawalt;25557119]Lua has OOP. I found myself saying "Lua doesn't have OOP" before, but that's not true at all. Lua has the facilities to even implement class-like OOP with metatables if you wanted.[/QUOTE]
Yeah Lua has OOP facilities, but they're way more of a hassle to use and things like delegates are either really hard to use effectively.
I would say give AngelScript a try. It's essentially C++ as a scripting language.
[QUOTE=Dotmister;25557157]Not sure what him being banned from facepunch has to do with you not using Kari,
Anyway, does turb_ have like a blog or something? I'd like to see what he's up to
Yeah Lua has OOP facilities, but they're way more of a hassle to use and things like delegates are either really hard to use effectively.[/QUOTE] I think you're thinking about it wrong. There's not one kind of OOP, I'd go as far as to say I PREFER Lua's OOP to languages that are strict about it. It feels fluent and natural, and it's extremely flexible. And you could easily do something like delegation in Lua.
[editline]21st October 2010[/editline]
[QUOTE=bladerunner627;25557225]I would say give AngelScript a try. It's essentially C++ as a scripting language.[/QUOTE]
Why even use a scripting language then?
[QUOTE=Jawalt;25557302]I think you're thinking about it wrong. There's not one kind of OOP, I'd go as far as to say I PREFER Lua's OOP to languages that are strict about it. It feels fluent and natural, and it's extremely flexible. And you could easily do something like delegation in Lua.
[editline]21st October 2010[/editline]
Why even use a scripting language then?[/QUOTE]
That's a really silly question. :v:
[QUOTE=BlkDucky;25557395]That's a really silly question. :v:[/QUOTE]
Not really, if you're going to use a scripting language you might as well use one that's a great margin easier to work with than the language you're using. I really wouldn't see a point other than not having to recompile, when you could get a lot more out of something like Python etc.
[QUOTE=Dotmister;25557157]Yeah Lua has OOP facilities, but they're way more of a hassle to use and things like delegates are either really hard to use effectively.[/QUOTE]
Not true, using the __index variable anything is possible!
Just so happens I was writing this when I saw your post:
[lua]
A = { ValueA = "A" }
A.__index = A
setmetatable( A, A )
B = { ValueB = "B" }
B.__index = B
setmetatable( B, B )
C = { ValueC = "C" }
C.__index = C
setmetatable( C, C )
D = { ValueD = "D", Parents = { A, B, C } }
function D:__newindex( Index, Value )
print( Index, Value )
end
function D:__index( Index )
-- Save the current __index function and reset our metatable stuff so we can look in our actual table instead of running in circles
local TempIndex = self.__index
self.__index = self
setmetatable( self, nil )
if( self[Index] ) then
return self
end
-- Restore this __index function
self.__index = TempIndex
setmetatable( self, self )
-- Look in the objects we inherit from
for k, v in pairs( self.Parents ) do
if( v[Index] ) then
return v[Index]
end
end
end
setmetatable( D, D )
print( D.ValueD ) -- "D"
print( D.ValueC ) -- "C"
print( D.ValueB ) -- "B"
print( D.ValueA ) -- "A"[/lua]
[QUOTE=Jawalt;25557474]Not really, if you're going to use a scripting language you might as well use one that's a great margin easier to work with than the language you're using. I really wouldn't see a point other than not having to recompile, when you could get a lot more out of something like Python etc.[/QUOTE]
Everyone always makes this argument but really it just personal preference.
Why learn a new language just for scripting if you're already really comfortable with another?
[QUOTE=bladerunner627;25557578]Everyone always makes this argument but really it just personal preference.
Why learn a new language just for scripting if you're already really comfortable with another?[/QUOTE]
Agreed.
[QUOTE=Jawalt;25557474]Not really, if you're going to use a scripting language you might as well use one that's a great margin easier to work with than the language you're using. I really wouldn't see a point other than not having to recompile, when you could get a lot more out of something like Python etc.[/QUOTE]
Why do you make it sound like not having to recompile as a minor thing?
[QUOTE=bladerunner627;25557578]
Why learn a new language just for scripting if you're already really comfortable with another?[/QUOTE]
Because a scripting language has completely different capabilities than whichever application programming language you're using, so you should choose a scripting language which takes advantage of that. Good scripting languages are very quick and easy to pick up anyway, and it'll save you a lot of time in the future over something as half-baked as AngelScript.
[QUOTE=jA_cOp;25557811]Because a scripting language has completely different capabilities than whichever application programming language you're using, so you should choose a scripting language which takes advantage of that. Good scripting languages are very quick and easy to pick up anyway, and it'll save you a lot of time in the future over something as half-baked as AngelScript.[/QUOTE]
Again this depends on a lot of factors, because learning a new language has learning curve, large or small it's still there and it's dependent on the developer too.
I'd also take the project size into consideration. If it's a small project with not too many scripts I don't really see a point in using a completely different language.
On the other hand if it's a very large project, like NS2 for example, then sure languages such as Lua will probably yield more productivity. You need to look at ease of implementation and all that too.
If you already know Lua, use Lua then, there's no right answer really..
One thing I love about AngelScript is the ease of binding. You bind a class and you basically inherit all that functionality in the script, easy as balls, no need for tons of code re-write.
To everyone talking about turb and kari,
I talk to him frequently and I'm sure he is going to keep working on that project, he just wont be posting about it here.
[QUOTE=CarlBooth;25556674]He burned his bridges, then pissed all over the ashes and smeared them up the wall.
He won't be back.[/QUOTE]
he can come back like chad
All he did was hijack someones account, unless I'm missing something.
What the fuck did Turb do?
[QUOTE=bladerunner627;25556404][cpp]
void VirtualMachine::ExecuteInstruction()
{
E_VM_INS instruction = m_pMemory[m_PC];
switch(instruction)
{
case ABA:
{
m_A += m_B;
++m_PC;
}
break;
case INCA:
{
++m_A;
++m_PC;
}
break;
case INCB:
{
++m_B;
++m_PC;
}
break;
case DECA:
{
--m_A;
++m_PC;
}
break;
case DECB:
{
--m_B;
++m_PC;
}
break;
case JNE:
{
if((m_CCR & 0x80) == 0)
{
++m_PC;
uint16_t addy = *((uint16_t*)(m_pMemory + m_PC));
m_PC = addy;
}
else
m_PC += 3;
}
break;
case LDAI:
{
++m_PC;
m_A = m_pMemory[m_PC];
++m_PC;
}
break;
case LDBI:
{
++m_PC;
m_B = m_pMemory[m_PC];
++m_PC;
}
break;
case CMPAI:
{
++m_PC;
int8_t cmp = m_A - m_pMemory[m_PC];
uint8_t par = (parity(cmp) << 1);
m_CCR = par; // Set parity flag in CCR
m_CCR |= cmp < 0 ? (1 << 4) : 0; // Set negative flag in CCR.
m_CCR = cmp == 0 ? (m_CCR | 0x80) : m_CCR;
++m_PC;
}
break;
case BNE:
{
if((m_CCR & 0x80) == 0)
{
++m_PC;
uint16_t addy = *((uint16_t*)(m_pMemory + m_PC));
m_PC += 2;
// Push registers on to stack.
--m_SP;
m_pMemory[m_SP] = static_cast<E_VM_INS>(m_A);
--m_SP;
m_pMemory[m_SP] = static_cast<E_VM_INS>(m_B);
--m_SP;
m_pMemory[m_SP] = static_cast<E_VM_INS>(m_CCR);
// Push program counter on to stack.
--m_SP;
m_pMemory[m_SP] = static_cast<E_VM_INS>((m_PC & 0xFF00));
--m_SP;
m_pMemory[m_SP] = static_cast<E_VM_INS>((m_PC & 0x00FF));
m_PC = addy;
}
else
m_PC += 3;
}
break;
case RTS:
{
m_PC = *((uint16_t*)(m_pMemory+m_SP));
m_SP += 4;
m_CCR = *((uint8_t*)(m_pMemory));
++m_SP;
m_B = *((uint8_t*)(m_pMemory));
++m_SP;
m_A = *((uint8_t*)(m_pMemory));
++m_SP;
}
break;
case END:
{
m_bEnd = true;
break;
}
case CMPAM:
break;
default:
m_bEnd = true;
break;
}
}
[/cpp][/QUOTE]
Looks cool, but you definitely need indirection. Maybe this helps?
[code]
case LDAIP:
{
++m_PC;
m_A = m_pMemory[m_pMemory[m_PC]];
++m_PC;
}
break;
[/code]
Also, I don't see any STAI or STBI :x
Nonetheless, nice work :smile:
[editline]22nd October 2010[/editline]
[QUOTE=geel9;25559356]What the fuck did Turb do?[/QUOTE]
He leaked some private forum stuff or something like that
[QUOTE=geel9;25559356]What the fuck did Turb do?[/QUOTE]
He made a public GMF and Mod Section viewer.
[QUOTE=i300;25560547]He made a public GMF and Mod Section viewer.[/QUOTE]
Is that bad?
[QUOTE=polkm;25560663]Is that bad?[/QUOTE]
Well derp it is. Anyone could view GMF or the Mod Section.
I love Valgrind.
==7317== HEAP SUMMARY:
==7317== in use at exit: 0 bytes in 0 blocks
==7317== total heap usage: 45,624 allocs, 45,624 frees, 2,362,839 bytes allocated
[QUOTE=i300;25560687]Well derp it is. Anyone could view GMF or the Mod Section.[/QUOTE]
I didn't know the mod section discussed federal secrets. It seams immature to ban someone for that but I guess if the mods want that much secrecy they can have it.
It's a general rule that if something is off-limits, you'll get in trouble for making it available to the public.
[QUOTE=geel9;25561511]It's a general rule that if something is off-limits, you'll get in trouble for making it available to the public.[/QUOTE]
You should always question authority. Fight the powwa! O.o
Nothing like a good serving of request forgery before bed!
[img_thumb]http://anyhub.net/file/last.fm.ripper.png[/img_thumb]
I've been working on my Last.fm ripper and it's currently working. The gibberish ASCII in the console means that it's working. :v:
[QUOTE=polkm;25561535]You should always question authority. Fight the powwa! O.o[/QUOTE]
suck my ball sack
[QUOTE=TH89;25562072]suck my ball sack[/QUOTE]
TH89 is a programmer?
[QUOTE=polkm;25560663]Is that bad?[/QUOTE]
If you knew what went on in GMF you would know why it's bad.
[QUOTE=Siemens;25560287]Looks cool, but you definitely need indirection.[/QUOTE]
Yeah I took it out cause I'm still working on the assembler. :smile:
Sorry, you need to Log In to post a reply to this thread.