mirror of
https://github.com/antoinevignau/source.git
synced 2024-06-06 17:29:39 +00:00
Vn+1
First try of condition...
This commit is contained in:
parent
84f4b4d035
commit
f50fe0abdb
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
@ -1431,28 +1431,22 @@ y_coord = *
|
||||||
--^
|
--^
|
||||||
|
|
||||||
x_text = *
|
x_text = *
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
]x = 0 ; Premi<6D>re colonne
|
]x = 0 ; Premi<6D>re colonne
|
||||||
lup max_colonnes
|
lup max_colonnes
|
||||||
dw ]x
|
dw ]x,]x,]x,]x,]x,]x,]x,]x
|
||||||
dw ]x
|
|
||||||
dw ]x
|
|
||||||
dw ]x
|
|
||||||
]x = ]x+1
|
]x = ]x+1
|
||||||
--^
|
--^
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
|
dw -1,-1,-1,-1,-1,-1,-1,-1
|
||||||
|
|
||||||
y_text = *
|
y_text = *
|
||||||
]y = 0 ; Premi<6D>re ligne
|
]y = 0 ; Premi<6D>re ligne
|
||||||
lup max_lignes
|
lup max_lignes
|
||||||
dw ]y
|
dw ]y,]y,]y,]y,]y,]y,]y,]y,]y,]y
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
dw ]y
|
|
||||||
]y = ]y+max_colonnes
|
]y = ]y+max_colonnes
|
||||||
--^
|
--^
|
||||||
|
|
||||||
|
@ -1719,17 +1713,26 @@ test_curseur
|
||||||
sta x1
|
sta x1
|
||||||
lda taskWHERE
|
lda taskWHERE
|
||||||
sta y1
|
sta y1
|
||||||
|
|
||||||
|
lda #' '
|
||||||
|
sta strX1
|
||||||
|
sta strX1+2
|
||||||
|
sta strY1
|
||||||
|
sta strY1+2
|
||||||
|
sta strX2
|
||||||
|
sta strX2+2
|
||||||
|
sta strY2
|
||||||
|
sta strY2+2
|
||||||
|
sta strIDX
|
||||||
|
sta strIDX+2
|
||||||
|
|
||||||
lda taskWHERE+2 ; X
|
lda taskWHERE+2 ; X
|
||||||
sec
|
asl
|
||||||
sbc #marge_gauche*largeur_caractere
|
|
||||||
bpl tc_1
|
|
||||||
lda #0
|
|
||||||
tc_1 asl
|
|
||||||
tax
|
tax
|
||||||
lda x_text,x
|
lda x_text,x
|
||||||
bmi tc_2
|
bpl tc_1
|
||||||
sta x2
|
lda #0
|
||||||
|
tc_1 sta x2
|
||||||
pha
|
pha
|
||||||
|
|
||||||
lda taskWHERE ; Y
|
lda taskWHERE ; Y
|
||||||
|
@ -1744,25 +1747,71 @@ tc_1 asl
|
||||||
sta idx
|
sta idx
|
||||||
pla ; on a l'index dans le texte
|
pla ; on a l'index dans le texte
|
||||||
|
|
||||||
lda texte_liens,x
|
lda texte_index,x
|
||||||
and #$ff
|
and #$ff
|
||||||
cmp #FALSE
|
ora #'0'
|
||||||
beq tc_2
|
sep #$20
|
||||||
|
sta strHIT
|
||||||
sep #$20 ; c'est un mot cliquable
|
|
||||||
ldal $c034
|
|
||||||
inc
|
|
||||||
stal $c034
|
|
||||||
rep #$20
|
rep #$20
|
||||||
|
|
||||||
tc_2 rts
|
|
||||||
|
|
||||||
|
PushWord x1
|
||||||
|
PushLong #strX1
|
||||||
|
PushWord #4
|
||||||
|
_Int2Hex
|
||||||
|
|
||||||
|
PushWord y1
|
||||||
|
PushLong #strY1
|
||||||
|
PushWord #4
|
||||||
|
_Int2Hex
|
||||||
|
|
||||||
|
PushWord x2
|
||||||
|
PushLong #strX2
|
||||||
|
PushWord #4
|
||||||
|
_Int2Hex
|
||||||
|
|
||||||
|
PushWord y2
|
||||||
|
PushLong #strY2
|
||||||
|
PushWord #4
|
||||||
|
_Int2Hex
|
||||||
|
|
||||||
|
PushWord idx
|
||||||
|
PushLong #strIDX
|
||||||
|
PushWord #4
|
||||||
|
_Int2Hex
|
||||||
|
|
||||||
|
PushWord #150
|
||||||
|
PushWord #150
|
||||||
|
_MoveTo
|
||||||
|
PushLong #string
|
||||||
|
_DrawCString
|
||||||
|
|
||||||
|
ldal KBD-1
|
||||||
|
bmi boum
|
||||||
|
rts
|
||||||
|
boum stal KBDSTROBE-1
|
||||||
|
|
||||||
|
lda #texte_index
|
||||||
|
brk $bd
|
||||||
|
|
||||||
x1 ds 2
|
x1 ds 2
|
||||||
y1 ds 2
|
y1 ds 2
|
||||||
x2 ds 2
|
x2 ds 2
|
||||||
y2 ds 2
|
y2 ds 2
|
||||||
idx ds 2
|
idx ds 2
|
||||||
|
|
||||||
|
string asc 'X1='
|
||||||
|
strX1 asc ' '
|
||||||
|
asc ' Y1='
|
||||||
|
strY1 asc ' '
|
||||||
|
asc ' X2='
|
||||||
|
strX2 asc ' '
|
||||||
|
asc ' Y2='
|
||||||
|
strY2 asc ' '
|
||||||
|
asc ' IDX='
|
||||||
|
strIDX asc ' '
|
||||||
|
asc ' HIT='
|
||||||
|
strHIT asc ' '00
|
||||||
|
|
||||||
*-----------------------
|
*-----------------------
|
||||||
* CHARGE_IMAGE - OK
|
* CHARGE_IMAGE - OK
|
||||||
*-----------------------
|
*-----------------------
|
||||||
|
@ -2024,8 +2073,8 @@ mc_3 ldy #0
|
||||||
cpy len_max
|
cpy len_max
|
||||||
bcc ]lp
|
bcc ]lp
|
||||||
|
|
||||||
jsr test_condition ; on a trouvŽ le mot
|
jsr test_condition ; vŽrifie s'il est cliquable
|
||||||
bra mc_6
|
bra mc_6 ; mot suivant
|
||||||
|
|
||||||
mc_5 inx
|
mc_5 inx
|
||||||
cpx #max_colonnes*max_lignes
|
cpx #max_colonnes*max_lignes
|
||||||
|
@ -2050,25 +2099,48 @@ mc_99 rep #$20 ; on sort
|
||||||
* si le mot est cliquable on remplit texte_liens
|
* si le mot est cliquable on remplit texte_liens
|
||||||
|
|
||||||
|
|
||||||
mx %10
|
mx %00
|
||||||
|
|
||||||
test_condition
|
test_condition
|
||||||
* rep #$20
|
rep #$20
|
||||||
phx ; 3,s
|
phx ; 3,s
|
||||||
phy ; 1,s
|
phy ; 1,s
|
||||||
|
|
||||||
* condition&=condition&(scene_actuelle|,i%)
|
* condition&=condition&(scene_actuelle|,i%)
|
||||||
|
|
||||||
* lda index_mot
|
lda index_mot
|
||||||
* asl
|
asl
|
||||||
* clc
|
clc
|
||||||
* adc localOFFSET
|
adc localOFFSET
|
||||||
* tax
|
tax
|
||||||
* lda condition,x
|
lda condition,x ; xxx2B ou yy2D
|
||||||
|
pha
|
||||||
|
and #$ff00 ; index dans scene_visitee
|
||||||
|
xba
|
||||||
|
tax
|
||||||
|
lda scene_visitee-1,x
|
||||||
|
and #$ff
|
||||||
|
tax ; true ou false
|
||||||
|
pla
|
||||||
|
and #$00ff ; 2B ou 2D
|
||||||
|
|
||||||
|
* IF (condition&>0 AND scene_visitee!(ABS(condition&))=TRUE) OR (condition&<0 AND scene_visitee!(ABS(-condition&))=FALSE)
|
||||||
|
|
||||||
|
cmp #'+'
|
||||||
|
bne tc_moins
|
||||||
|
cpx #TRUE
|
||||||
|
beq tc_addmot
|
||||||
|
bne tc_prendpas
|
||||||
|
|
||||||
|
tc_moins cpx #FALSE
|
||||||
|
bne tc_prendpas
|
||||||
|
|
||||||
|
tc_addmot ply ; marque le mot dans les buffers
|
||||||
|
plx
|
||||||
|
sep #$20
|
||||||
]lp dex
|
]lp dex
|
||||||
dey
|
dey
|
||||||
bmi tc_99
|
bmi tc_ok ; on sort sans dŽpiler
|
||||||
lda #colorWHITE
|
lda #colorWHITE
|
||||||
sta texte_liens,x
|
sta texte_liens,x
|
||||||
lda index_mot
|
lda index_mot
|
||||||
|
@ -2076,15 +2148,14 @@ test_condition
|
||||||
sta texte_index,x
|
sta texte_index,x
|
||||||
bra ]lp
|
bra ]lp
|
||||||
|
|
||||||
* IF (condition&>0 AND scene_visitee!(ABS(condition&))=TRUE) OR (condition&<0 AND scene_visitee!(ABS(-condition&))=FALSE)
|
tc_prendpas ply
|
||||||
|
|
||||||
tc_99 ply
|
|
||||||
plx
|
plx
|
||||||
|
|
||||||
tc_ok
|
tc_ok sep #$20
|
||||||
* sep %20
|
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
mx %00
|
||||||
|
|
||||||
*-----------------------
|
*-----------------------
|
||||||
* MUSIQUE - OK
|
* MUSIQUE - OK
|
||||||
*-----------------------
|
*-----------------------
|
||||||
|
|
Binary file not shown.
Loading…
Reference in New Issue
Block a user