Jhenna Foronda
Jhenna Foronda

Reputation: 35

simple Frogger game MIPS assembly

I am trying to create a simple frogger game, but when I run my code in MIPS, it throws the error

Frogger line 39 column 2: "addi": Too many or incorrectly formatted operands. 
Expected: addi $t1,$t2,-100`
.data
World: .ascii "____f____"
XCoord: .byte 4
under: .ascii "_"
frog: .ascii "f"

// function that displays "world" string   
emitworld:
addi $ra, $ra, -4($sp)
sw $ra, 0($sp)
jal emitseq

lw $ra, 0($sp)
addi $ra, $ra, 4($sp)
jr $ra

Upvotes: 0

Views: 1065

Answers (1)

Janus Troelsen
Janus Troelsen

Reputation: 21300

as you can see from documentation, the third value has to be an immediate.

try add instead.

Upvotes: 1

Related Questions