generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Lua Assembly

Previous Thread :: Next Thread 
ENET is not online. ENET
Joined: 01 Jan 2010
Total Posts: 4820
28 May 2012 11:12 PM
I am trying to learn lua asm from A No Frills Intro To Lua, but it just doesn't explain encoding a Instruction very well.

There are three instruction forms. iABC, iABx, IAsBx



iABC(B9, C9, A8, Op6)
iABx(Bx18, A8, Op6)
iABC(sBx18, A8, Op6)

SETGLOBAL(7) Write a register value into a global variable

SETGLOBAL A Bx Gbl[Kst(Bx)] := R(A)

Which means setGlobal would have to use iABx instruction form.

ADDR _= =_ DATA____ = Equivalence
0037 _= =_ 47400000 = setglobal 1 1

so...
07 1 1

A=1 Bx=1
Op = 07


Op is 6 bits
Bx is 18 bits
A is 8 bits

4740 0000
0100 0111 0100 0000
0000 0000 0000 0000

0100 01 is not equal to 7!
and 00 0000 is not equal to 7!
Where the heck does this come out to op code 7?!
Report Abuse
Multidimensional is not online. Multidimensional
Joined: 05 Apr 2012
Total Posts: 866
28 May 2012 11:36 PM
You're good.
Report Abuse
ENET is not online. ENET
Joined: 01 Jan 2010
Total Posts: 4820
28 May 2012 11:42 PM
I'm asking for help. I want to be able to decipher one simple instruction!
Report Abuse
Multidimensional is not online. Multidimensional
Joined: 05 Apr 2012
Total Posts: 866
28 May 2012 11:45 PM
Calm down. I'm sure someone who knows Assembly will soon be here to help.
Report Abuse
ENET is not online. ENET
Joined: 01 Jan 2010
Total Posts: 4820
28 May 2012 11:51 PM
I know assembly. But the lua assembly confuses me or this guide has the wrong hexcode for this op example.
Report Abuse
jrf2112 is not online. jrf2112
Joined: 29 Jun 2008
Total Posts: 3354
29 May 2012 09:13 AM
You can google numbers-hexcode translator and get a correct hexcode.
Report Abuse
ENET is not online. ENET
Joined: 01 Jan 2010
Total Posts: 4820
29 May 2012 09:15 AM
Your not listening. I know how to convert binary->hex->decimal.... I am asking about instruction format!
Report Abuse
jrf2112 is not online. jrf2112
Joined: 29 Jun 2008
Total Posts: 3354
29 May 2012 09:19 AM
I think I get how it works, but I'm probably going to be wrong. Good luck.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image