(fixed) Problem with search_quiv_for_ammo

This forum is for the Lua scriptable clone of DM/CSB called Dungeon Strikes Back by Sophia. Use DSB to build your own highly customised games.

Moderator: Sophia

Forum rules
Please read the Forum rules and policies before posting. You may Image to help finance the hosting costs of this forum.
Post Reply
User avatar
Joramun
Mon Master
Posts: 927
Joined: Thu May 25, 2006 7:05 pm
Location: The Universe

(fixed) Problem with search_quiv_for_ammo

Post by Joramun »

In methods.lua : function get_more_throwing_ammo :

LUA ERROR: Lua Function THROW: base/methods.lua:894: dsb_set_gfxflag requires int in param 1

It is calling for the ammo id, or in my case :
ammo = search_quiv_for_ammo(...)
where :
search_quiv_for_ammo returns false (since the quiver is empty) resulting in an error...

That's all ! :wink:
What Is Your Quest ?
User avatar
Sophia
Concise and Honest
Posts: 4306
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Oops.

Change line 893 (the one right above this error) of methods.lua from "else" to "elseif (ammo) then" and this should work.
Post Reply