### Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

### Messages - PhoenixII54

Pages: [1] 2 3
1
« on: June 14, 2018, 04:21:26 pm »
i tried using your script on my own test map, and it worked perfectly*. The only warning for you is that the movement will stop if your NPC reaches an obstacle. And i have to correct myself : the parenthesis are actually optionnal for a function call with a raw table data for only argument.

*using an already fully configured sprite (ALTTP Zelda)

PS, that means something is likely wrong on your sprite data, and of course your path is wrong : for a back-and-forth movement, you should use opposite directions, (0+4,1+5, 2+6 or 3+7).

2
« on: June 14, 2018, 02:33:00 pm »
i think the final problem in your script is that you didn't add the parenthesis around the path data table, and as a consequence the movement:set_path function is not called, resulting in the movement path to not be set at all (note : each path direction is numbered from 0 (east) to 7 (south-east), using the trigonometric rotation (or if you prefer the anti-clockwise rotation))

PS : as max said, using
Code: [Select]
`[code= lua]`  at start of your code is helpful indeed

3
« on: June 14, 2018, 02:05:25 pm »
To be simple, "Boolean"  refers to a binary variable which can mean true (value=1) or false (value=0)

PS :
to understand the importance of boolean concept, remember that the whole modern conputing concept is based of the Boole algebra

4
« on: June 14, 2018, 01:50:31 pm »
Well, at least you got some progress, and that is the most important thing.

your next step is to make your animation loop, and it is fairly simple : right before starting it, just call movement:set_loop(<boolean value>).
Result will be a continuous movement, which will either do a full back-and-forth movement like you intend, or your npc will just go out of the screen forever -or at least until you leave the map or quit the game.

5
« on: June 14, 2018, 01:11:31 pm »
Now this is strange, did you add all four directions in your "walking" anmation set?
If yes, then did you set sprite data to each direction? i suppose that you did, but i wanted to have confirmation

PS : Now that i think, did you create the "walking" set at all ?Again, I suppose that you did, but I wanted to have confirmation

6
« on: June 14, 2018, 11:22:25 am »
Self-quote from before, since it is an already known issue :

The problem is that the engine expects NPC to have 4 sprite directions, and i suppose you only put 2 in your animation. To fix this, you must duplicate some of its directions to have all 4 required, in case you want to add more to the path.

Another thing to precise is that your movement might not loop as you scripted it.Use movement:set_loop() to define whever you want it to loop or not.

Also, you can use timers to enhance your moves, like, walk to point A, wait, turn left, wait, go to point B, wait, etc. I suppose it is not in your priorities yet, but it will definetely add live to your NPC.

Precision : Sprite directions counting always starts from 0, by convention. and reference to : right (0), up (1), left(2) and down (3).

Yes, programming can be difficult, especially for beginners, but by training and not fearing to make mistakes, you will make constant progress as long as you take the time to understand why a particular mistake has been done.

Anyway, hope it helps you fixing this error

7
« on: June 13, 2018, 01:35:21 pm »
Aww, i think there are some basic Lua notions you need to understand :

1. when you define functions using
Code: Lua
1. function <id>
, the content of the parenthesis is the declaration of variable(s) that you want to be passed on call
so doing
Code: Lua
1. function map:on_started(movement:start(traveller_2))
is not correct and is likely to generate odd behaviour if not triggering an error.

2. in line :
Code: Lua
1.   movement:set_path{4,4,4,4,4,0,0,0,0,0}
you forgot the parenthesis around the list content, since you wnt to call the set_path function. (which may be why you got the error message in the first place)

3. finally, your movement will never be started since your function call is misplaced (see 1.).

That's all for now, try fixing your script from all points above, and let me know if it is OK.

8
##### Your projects / Zelda MoS DX - Boss Keys-style progression graphic
« on: June 12, 2018, 11:35:48 pm »
Hello everybody,

Lately, I have been watching a series called "Boss Keys", made by Mark Brown (channel) , who intended to analyze all Zelda games, and building a progression graphics from critical path.
As a challenge, and pushed by the Gitter chat people, I decided to train myself on the Solarus team's first game: Zelda Mystery of Solarus DX.

And... what you are about to see is the result of my analyzis work: a full graph of every dungeon, including the secret one.

Feel free to make any remark and/or suggestion, i'll be glad to answer/enhance it all.

Enjoy!

9
##### Zelda Mystery of Solarus XD / Re: Is this supposed to happen: episode 2 (for Mercuris Chess)
« on: June 05, 2018, 04:17:10 pm »
Yup, there is a way to fix it, too.

Hint : Find an official iPhone iFeather provider...

10
« on: June 03, 2018, 03:24:56 pm »
1. you are trying to call a reference of movement, but it doesn't exist anymore (when the on_started function finishes, everything defined with local in it is destroyed -or restored to it's previous value if it was already declared outside)
2. you are redeclaring the start() function, which works, because lua allows it, but in your case, would just anihilate it's normal behavior, and as such,  never trigger the movement to actually start.

To fix it, you must place your movement:start inside the on_started function, and remove the function keyword (as well as the associated end keyword)

11
« on: May 28, 2018, 02:27:34 pm »

Code: Lua
1. local movement = sol.movement.create("path")
2.   movement:set_path{4,4,4,4,4,0,0,0,0,0}
3.   movement:set_speed(20)
4.
5. movement:start(traveller2)
6. end

Either this a copy-paste error, or you did forget the function decleration, but in any case, if i executed it, i would get this error message (not in this exact format, but whatever) :
Code: [Select]
`Error : unexpected symbol "end" at line 13:1`

12
« on: May 25, 2018, 11:20:45 am »
The problem is that the engine expects NPC to have 4 sprite directions, and i suppose you only put 2 in your animation. To fix this, you must duplicate some of its directions to have all 4 required, in case you want to add more to the path.

Another thing to precise is that your movement might not loop as you scripted it.Use movement:set_loop() to define whever you want it to loop or not.

Also, you can use timers to enhance your moves, like, walk to point A, wait, turn left, wait, go to point B, wait, etc. I suppose it is not in your priorities yet, but it will definetely add live to your NPC.

13
##### Bugs & Feature requests / Re: Solarus Ubuntu 18.04 build fail?
« on: May 24, 2018, 03:50:01 pm »
Hello,

Another solution is to compile the sources directly, and on Linux it much easy thanks to command line

Explanations how to do it are here (explanations are for v1.5.X).

Hope it helps !

14
« on: May 22, 2018, 10:23:08 am »
Quote
Could you provide examples of where it's particularly hazardous? I could probably put in some rocks or something to block it off
in maps Plain of Andor/af21 and Plain of Andor/ae21, Plain of Andor/ah21, : the border between shallow and deep water (especially the swallow side), is the best example of it (just walk north there and you'll be continuously be drown until game over)
Plain of Andor/ah20, same idea with the right side of the river

15
« on: May 18, 2018, 02:10:39 pm »
UPDATE : in latest commit, tree stomp/cabin behind merchand of map Ogbam/af26 is partially traversable

on the other topic
Quote
One thing I'm debating over is reshaping the river separating the Plain from the rest of the overworld. I did my best to try and replicate how it looked in the original game, but I'm not sure I like how it looks and can potentially interfere with moving between screens. So my thought is to simply make it nice and straight across with few curves whatsoever, but if it stays the way it is then it's no skin off my nose. Anybody who plays it, can you give me your thoughts on it?
Reference map: https://i.imgur.com/6seyD8Qr.jpg

one thing to be aware of is that you could fall in the deep water right after a transition if you make a diagonal near the map border (EDIT (2:36 PM french time): aaand, i just got stuck and drowned), so you whould avoiding it when possible, either by making it straight or by adding some obstacles
Anyway, it's general shape looks okay to me.

EDITÂ² Not related, but : i think the Octos are broken/not finished (commit 74fcf05805bf16facff805d5b6ec82ae43858062):

Code: [Select]
`Error: In timer callback: enemies/octorok.lua:57: attempt to call method 'go' (a nil value)stack traceback:[C]: in function 'go'enemies/octorok.lua:57: in function <enemies/octorok.lua:49>`

Pages: [1] 2 3