Maybe it's a stupid question, but how can I get my useractor to open a door when I press the spacebar?
I have a room with a few pictures on the wall. One spot is empty. The player has to get a picture from a different room and put it in place, then a door should open.
My Code for the picture + pickup:
//The PICWALLSPRITE - Empty spot where picture should go useractor notenemy PICWALLSPRITE cstat 16 ifp pfacing ifpdistl 1024 { ifvare gotpicture 0 { ifhitspace { sound DUKE_SEARCH quote 130 } } else { ifhitspace { sound DUKE_SEARCH subvar gotpicture 1 strength 20 quote 132 cactor PICONWALL } } } enda //PICONWALL - The picture on the wall useractor notenemy PICONWALL 20 cstat 273 spritepal 0 ifp pfacing ifpdistl 1024 { ifhitspace { quote 133 sleeptime 128 } } enda //The picture-pickup useractor notenemy PICPICKUP sizeat 50 50 cstat 273 ifvare gotpicture 0 ifpdistl 1024 { ifhitspace { sound SELECT_WEAPON palfrom 16 0 64 0 quote 131 addvar gotpicture 1 killit } } enda
Thanks in advance!