Community
Community Affairs => Forum Support and Suggestions => Topic started by: JRedant on June 28, 2019, 08:26:02 PM
-
Hey guys! Long time no see.
So I'm starting up a live stream of real-time game development.
And I find myself stuck. What am I doing wrong?
Here is the page in question:
http://scicompanion.com/Documentation/Tutorial/RoomBackground.html
And here is the code that I think I'm supposed to be using:
(instance rm110 of Room
(properties
picture 110
style (| dpANIMATION_BLACKOUT dpOPEN_FADEPALETTE)
horizon 50
vanishingX 130
vanishingY 50
noun N_ROOM
)
(method (init)
(AddPolygonsToRoom @P_Default110)
(super init:)
(switch gPreviousRoomNumber
; Add room numbers here to set up the ego when coming from different directions.
(else
(SetUpEgo -1 1)
(gEgo posn: 60 130)
)
)
(gEgo init:)
; We just came from the title screen, so we need to call this to give control
; to the player.
(gGame handsOn:)
(theBox
approachVerbs: V_DO
init:
)
(redBox
approachVerbs: V_DO
init:
)
(painting:
setOnMeCheck(omcPOLYGON CreateNewPolygon(@P_Painting))
init()
)
)
)
This is throwing out the following error:
Error: Expected an expression (111,3): "painting"
Where did I mess up?
-
This looks like a weird mix of SCI Studio and Sierra syntax. In particular, the expression that's throwing an error is in SCI Studio syntax. You can change it as follows:
(painting
setOnMeCheck: omcPOLYGON (CreateNewPolygon @P_Painting)
init:)
(oh, I see it comes from the page you linked to...)
I haven't tested this btw, I just rewrote it mechanically in the new syntax.
-
Go to the picture editor, draw a polygon named "Painting".
-
Kawa: Did that.
-
This looks like a weird mix of SCI Studio and Sierra syntax. In particular, the expression that's throwing an error is in SCI Studio syntax. You can change it as follows:
(painting
setOnMeCheck: omcPOLYGON (CreateNewPolygon @P_Painting)
init:)
(oh, I see it comes from the page you linked to...)
I haven't tested this btw, I just rewrote it mechanically in the new syntax.
Yup! That worked. Thank you.
Who do I report to to have that code changed?
-
That's resolved and working as expected.
I think I inadvertently became a Beta Tester for the new API.
-
Yup! That worked. Thank you.
Who do I report to to have that code changed?
That would be up to Phil.
BTW, welcome back, JRedant.
-
Thank you!
Oh incidentally . . . this is all part of my current project . . . a kind of real-time development on YouTube, where I steam every single part of the game development.
Game Dev (Werewolves and Wanderer): https://www.youtube.com/playlist?list=PLUXBHpzHsJ3oiIP7JKf7vpBQrmp7LqEl7
So it will be dull and boring.
It does keep me going with my interest factor.
I watched too many critic videos and video gaming streams. I get bored when I try to do one. And kept thinking "there isnt any point to this is there?" I can tear apart games like AVGN or Markiplier. I can be a self pompous jerk like Darksydephil or Nostalgia Critic. Or I could look in depth in games and give thoughtful reviews like Rerez.
None of that interests me.
I would rather make one.
If anything, just to show people how long the process takes and how much passion and patience you need to make one. From start to finish.
That's my drive for this project and i might be able to finish it this time.
-
Who do I report to to have that code changed?
You can just send Phil a pull request via github. The source for this page can be found here:
https://github.com/icefallgames/SCICompanion/blob/master/SCICompanion/Docs/source/Tutorial/RoomBackground.rst (https://github.com/icefallgames/SCICompanion/blob/master/SCICompanion/Docs/source/Tutorial/RoomBackground.rst)
-
Okay . . . I'm an idiot. The Fill button is not working for me.
So, I should be logically seeing something filled in with a very dark due of grey.
And no matter where I click, nothing is being filled.
What am I doing wrong?
-
I found a work-around. I just can't explain why it works.
I added in a new picture, and now it works just fine.
-
Palette question:
So I just defined 16 colors to go along with the 64 pinned colors. So how come it looks different in the actual game (save --> compile all --> rebuild resources) than it does in the picture editor? (desired effect: I want the door to be blue)
-
Palette insertion vs. replacement... somewhere in your workflow you have a palette that contains the old palette entries (most likely the ego view?), and since it is loaded later than the pic, its old entries replace the altered ones in the pic.
-
Hmm . . solution?
Do I go in to the Ego View and match the palettes? Would that do it?
-
Oh . . . wait, I see it.
This is my title screen. I had imported an image which generated a different palette. The generated palette colours for 64 and 65 seem to be crossing over from the title screen.
Yeah. . . that's the problem.
-
Okay . . . is there a way to set it so that Title Screen can use "Palette 1" and room 1 can use "Palette 2"?
Or am I married to one and only palette through the entire game?
-
. . . and it was that easy:
(method (doit)
(super doit:)
(Palette palSET_FROM_RESOURCE 001 2)
)
Resolved.
-
Hey JRedant, I had a similar issue: http://sciprogramming.com/community/index.php?topic=1780.msg11684#msg11684 (http://sciprogramming.com/community/index.php?topic=1780.msg11684#msg11684). I was able to use the same workaround that you described by setting the palette in the doit method, but it just feels wrong.
-
You should just be able to do it in the init method shouldn't you?